Search in sources :

Example 1 with UploadCommand

use of com.github.games647.changeskin.bungee.command.UploadCommand in project ChangeSkin by games647.

the class ChangeSkinBungee method onEnable.

@Override
public void onEnable() {
    logger = CommonUtil.createLoggerFromJDK(getLogger());
    core = new ChangeSkinCore(this);
    try {
        core.load(true);
    } catch (Exception ioExc) {
        logger.error("Error initializing plugin. Disabling...", ioExc);
        return;
    }
    PluginManager pluginManager = getProxy().getPluginManager();
    pluginManager.registerListener(this, new ConnectListener(this));
    pluginManager.registerListener(this, new ServerSwitchListener(this));
    // this is required to listen to messages from the server
    getProxy().registerChannel(getName());
    pluginManager.registerListener(this, new MessageListener(this));
    // register commands
    pluginManager.registerCommand(this, new SetCommand(this));
    pluginManager.registerCommand(this, new InvalidateCommand(this));
    pluginManager.registerCommand(this, new UploadCommand(this));
    pluginManager.registerCommand(this, new SelectCommand(this));
    pluginManager.registerCommand(this, new InfoCommand(this));
}
Also used : PluginManager(net.md_5.bungee.api.plugin.PluginManager) ChangeSkinCore(com.github.games647.changeskin.core.ChangeSkinCore) ServerSwitchListener(com.github.games647.changeskin.bungee.listener.ServerSwitchListener) UploadCommand(com.github.games647.changeskin.bungee.command.UploadCommand) InfoCommand(com.github.games647.changeskin.bungee.command.InfoCommand) MessageListener(com.github.games647.changeskin.bungee.listener.MessageListener) SelectCommand(com.github.games647.changeskin.bungee.command.SelectCommand) ConnectListener(com.github.games647.changeskin.bungee.listener.ConnectListener) InvalidateCommand(com.github.games647.changeskin.bungee.command.InvalidateCommand) SetCommand(com.github.games647.changeskin.bungee.command.SetCommand)

Example 2 with UploadCommand

use of com.github.games647.changeskin.bungee.command.UploadCommand in project ChangeSkin by games647.

the class ChangeSkinBukkit method registerCommands.

private void registerCommands() {
    getCommand("setskin").setExecutor(new SetCommand(this));
    getCommand("skinupdate").setExecutor(new InvalidateCommand(this));
    getCommand("skinselect").setExecutor(new SelectCommand(this));
    getCommand("skinupload").setExecutor(new UploadCommand(this));
    getCommand("skinskull").setExecutor(new SkullCommand(this));
    getCommand("skin-info").setExecutor(new InfoCommand(this));
}
Also used : SkullCommand(com.github.games647.changeskin.bukkit.command.SkullCommand) UploadCommand(com.github.games647.changeskin.bukkit.command.UploadCommand) InfoCommand(com.github.games647.changeskin.bukkit.command.InfoCommand) SelectCommand(com.github.games647.changeskin.bukkit.command.SelectCommand) InvalidateCommand(com.github.games647.changeskin.bukkit.command.InvalidateCommand) SetCommand(com.github.games647.changeskin.bukkit.command.SetCommand)

Aggregations

InfoCommand (com.github.games647.changeskin.bukkit.command.InfoCommand)1 InvalidateCommand (com.github.games647.changeskin.bukkit.command.InvalidateCommand)1 SelectCommand (com.github.games647.changeskin.bukkit.command.SelectCommand)1 SetCommand (com.github.games647.changeskin.bukkit.command.SetCommand)1 SkullCommand (com.github.games647.changeskin.bukkit.command.SkullCommand)1 UploadCommand (com.github.games647.changeskin.bukkit.command.UploadCommand)1 InfoCommand (com.github.games647.changeskin.bungee.command.InfoCommand)1 InvalidateCommand (com.github.games647.changeskin.bungee.command.InvalidateCommand)1 SelectCommand (com.github.games647.changeskin.bungee.command.SelectCommand)1 SetCommand (com.github.games647.changeskin.bungee.command.SetCommand)1 UploadCommand (com.github.games647.changeskin.bungee.command.UploadCommand)1 ConnectListener (com.github.games647.changeskin.bungee.listener.ConnectListener)1 MessageListener (com.github.games647.changeskin.bungee.listener.MessageListener)1 ServerSwitchListener (com.github.games647.changeskin.bungee.listener.ServerSwitchListener)1 ChangeSkinCore (com.github.games647.changeskin.core.ChangeSkinCore)1 PluginManager (net.md_5.bungee.api.plugin.PluginManager)1