Refactored Package and Class Names

This commit is contained in:
AliLaptop 2016-06-25 20:49:33 -04:00
parent 59b9ca454f
commit b398fe0e33
12 changed files with 132 additions and 11 deletions

View file

@ -5,19 +5,21 @@ import java.util.logging.Logger;
import org.bukkit.plugin.PluginDescriptionFile;
import org.bukkit.plugin.java.JavaPlugin;
import buttondevteam.alisolarflare.aliarrowtrail.AliArrowListener;
import buttondevteam.alisolarflare.discordbot.DiscordSubPlugin;
import buttondevteam.alisolarflare.iiewar.IieWarSubPlugin;
public class MainPlugin extends JavaPlugin{
private PluginDescriptionFile pdfFile;
private Logger logger;
private AliArrowListener aliArrowListener;
private DiscordSubPlugin discordSubPlugin;
private IieWarSubPlugin iieWarSubPlugin;
public void onEnable(){
//Logs "Plugin Enabled", registers commands
pdfFile = getDescription();
logger = getLogger();
logger.info(pdfFile.getName() + " has been started (V." + pdfFile.getVersion()+ ").");
registerSubPlugins();
registerCommands();
registerEvents();
@ -26,16 +28,17 @@ public class MainPlugin extends JavaPlugin{
public void onDisable(){
logger.info(pdfFile.getName() + " has been Disabled (V." + pdfFile.getVersion()+ ").");
}
public void registerSubPlugins(){
discordSubPlugin = new DiscordSubPlugin(this);
iieWarSubPlugin = new IieWarSubPlugin(this);
discordSubPlugin.register();
iieWarSubPlugin.register();
}
public void registerCommands(){
//Example command: getCommand("createShrine").setExecutor(new CreateShrine(this));
}
public void registerEvents(){
//Example INIT: midnightListener = new MidnightListener(this);
//Example Event: getServer().getPluginManager().registerEvents(midnightListener, this);
//INIT
aliArrowListener = new AliArrowListener(this);
//EVENTS
getServer().getPluginManager().registerEvents(aliArrowListener, this);
}
}

View file

@ -0,0 +1,26 @@
package buttondevteam.alisolarflare.discordbot;
import java.util.logging.Level;
import buttondevteam.MainPlugin;
public class DiscordSubPlugin {
private MainPlugin plugin;
public DiscordSubPlugin(MainPlugin plugin){
this.plugin = plugin;
}
public void register(){
registerEvents();
registerCommands();
plugin.getLogger().log(Level.INFO, "Discord Sub Plugin Registered!");
}
private void registerEvents() {
}
private void registerCommands() {
// TODO Auto-generated method stub
}
}

View file

@ -0,0 +1,5 @@
package buttondevteam.alisolarflare.discordbot.commands;
public class Discord {
}

View file

@ -0,0 +1,16 @@
package buttondevteam.alisolarflare.discordbot.helpers;
public class DiscordBotLink {
public void setRoleAsMinecraft(){
}
public void unsetRoleAsMinecraft(){
}
public void setRoleAsFlair(){
}
public void unsetRoleAsFlair(){
}
}

View file

@ -0,0 +1,5 @@
package buttondevteam.alisolarflare.discordbot.listeners;
public class PrivateMessageListener {
}

View file

@ -0,0 +1,25 @@
package buttondevteam.alisolarflare.iiewar;
import java.util.logging.Level;
import buttondevteam.MainPlugin;
public class IieWarSubPlugin {
private MainPlugin plugin;
public IieWarSubPlugin(MainPlugin plugin){
this.plugin = plugin;
}
public void register(){
registerEvents();
registerCommands();
plugin.getLogger().log(Level.INFO, "Discord Sub Plugin Registered!");
}
private void registerEvents() {
}
private void registerCommands() {
// TODO Auto-generated method stub
}
}

View file

@ -0,0 +1,5 @@
package buttondevteam.alisolarflare.iiewar.commands;
public class ToggleWar {
}

View file

@ -0,0 +1,16 @@
package buttondevteam.alisolarflare.iiewar.helpers;
import org.bukkit.entity.Player;
public class WarListManager {
public void createWarList(){
//stub
}
public void LoadWarList(){
//stub
}
public boolean isOnList(Player player){
return false;
//stub
}
}

View file

@ -0,0 +1,5 @@
package buttondevteam.alisolarflare.iiewar.listeners;
public class CreativeListener {
}

View file

@ -0,0 +1,5 @@
package buttondevteam.alisolarflare.iiewar.listeners;
public class ObsidianListener {
}

View file

@ -0,0 +1,5 @@
package buttondevteam.alisolarflare.iiewar.listeners;
public class SpawnEggListener {
}

View file

@ -0,0 +1,5 @@
package buttondevteam.alisolarflare.iiewar.listeners;
public class TeleportListener {
}