Refactored Package and Class Names
This commit is contained in:
parent
59b9ca454f
commit
b398fe0e33
12 changed files with 132 additions and 11 deletions
|
@ -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);
|
||||
public void registerEvents(){
|
||||
//EVENTS
|
||||
getServer().getPluginManager().registerEvents(aliArrowListener, this);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -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
|
||||
|
||||
}
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
package buttondevteam.alisolarflare.discordbot.commands;
|
||||
|
||||
public class Discord {
|
||||
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
package buttondevteam.alisolarflare.discordbot.helpers;
|
||||
|
||||
public class DiscordBotLink {
|
||||
public void setRoleAsMinecraft(){
|
||||
|
||||
}
|
||||
public void unsetRoleAsMinecraft(){
|
||||
|
||||
}
|
||||
public void setRoleAsFlair(){
|
||||
|
||||
}
|
||||
public void unsetRoleAsFlair(){
|
||||
|
||||
}
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
package buttondevteam.alisolarflare.discordbot.listeners;
|
||||
|
||||
public class PrivateMessageListener {
|
||||
|
||||
}
|
25
src/buttondevteam/alisolarflare/iiewar/IieWarSubPlugin.java
Normal file
25
src/buttondevteam/alisolarflare/iiewar/IieWarSubPlugin.java
Normal 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
|
||||
|
||||
}
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
package buttondevteam.alisolarflare.iiewar.commands;
|
||||
|
||||
public class ToggleWar {
|
||||
|
||||
}
|
|
@ -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
|
||||
}
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
package buttondevteam.alisolarflare.iiewar.listeners;
|
||||
|
||||
public class CreativeListener {
|
||||
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
package buttondevteam.alisolarflare.iiewar.listeners;
|
||||
|
||||
public class ObsidianListener {
|
||||
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
package buttondevteam.alisolarflare.iiewar.listeners;
|
||||
|
||||
public class SpawnEggListener {
|
||||
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
package buttondevteam.alisolarflare.iiewar.listeners;
|
||||
|
||||
public class TeleportListener {
|
||||
|
||||
}
|
Loading…
Reference in a new issue