2016-06-23 18:08:25 +00:00
|
|
|
package buttondevteam;
|
|
|
|
|
|
|
|
import java.util.logging.Logger;
|
|
|
|
|
|
|
|
import org.bukkit.plugin.PluginDescriptionFile;
|
|
|
|
import org.bukkit.plugin.java.JavaPlugin;
|
|
|
|
|
2016-06-26 00:49:33 +00:00
|
|
|
import buttondevteam.alisolarflare.discordbot.DiscordSubPlugin;
|
|
|
|
import buttondevteam.alisolarflare.iiewar.IieWarSubPlugin;
|
2016-06-24 08:59:52 +00:00
|
|
|
|
2016-06-23 18:08:25 +00:00
|
|
|
public class MainPlugin extends JavaPlugin{
|
|
|
|
private PluginDescriptionFile pdfFile;
|
|
|
|
private Logger logger;
|
2016-06-26 00:49:33 +00:00
|
|
|
private DiscordSubPlugin discordSubPlugin;
|
|
|
|
private IieWarSubPlugin iieWarSubPlugin;
|
2016-06-23 18:08:25 +00:00
|
|
|
public void onEnable(){
|
|
|
|
//Logs "Plugin Enabled", registers commands
|
|
|
|
pdfFile = getDescription();
|
|
|
|
logger = getLogger();
|
|
|
|
logger.info(pdfFile.getName() + " has been started (V." + pdfFile.getVersion()+ ").");
|
2016-06-26 00:49:33 +00:00
|
|
|
|
|
|
|
registerSubPlugins();
|
2016-06-23 18:08:25 +00:00
|
|
|
registerCommands();
|
|
|
|
registerEvents();
|
|
|
|
|
|
|
|
logger.info(pdfFile.getName() + " has been Enabled (V." + pdfFile.getVersion()+ ").");
|
|
|
|
}
|
|
|
|
public void onDisable(){
|
|
|
|
logger.info(pdfFile.getName() + " has been Disabled (V." + pdfFile.getVersion()+ ").");
|
|
|
|
}
|
2016-06-26 00:49:33 +00:00
|
|
|
public void registerSubPlugins(){
|
|
|
|
discordSubPlugin = new DiscordSubPlugin(this);
|
|
|
|
iieWarSubPlugin = new IieWarSubPlugin(this);
|
|
|
|
|
|
|
|
discordSubPlugin.register();
|
|
|
|
iieWarSubPlugin.register();
|
|
|
|
}
|
2016-06-23 18:08:25 +00:00
|
|
|
public void registerCommands(){
|
|
|
|
//Example command: getCommand("createShrine").setExecutor(new CreateShrine(this));
|
|
|
|
}
|
2016-06-26 00:49:33 +00:00
|
|
|
public void registerEvents(){
|
2016-06-23 18:08:25 +00:00
|
|
|
//EVENTS
|
|
|
|
}
|
|
|
|
}
|