oldDirectory.renameTo(dataFolder);
}
private void registerEvents() {
// TODO Only register events that are being listened to
PluginManager pm = getServer().getPluginManager();
pm.registerEvent(Event.Type.PLAYER_COMMAND_PREPROCESS, playerListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.PLAYER_JOIN, playerListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.PLAYER_QUIT, playerListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.PLAYER_ITEM_HELD, playerListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.PLAYER_CHAT, playerListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.PLAYER_TELEPORT, playerListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.PLAYER_PICKUP_ITEM, playerListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.PLAYER_DROP_ITEM, playerListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.PLAYER_INTERACT, playerListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.BLOCK_PLACE, blockListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.BLOCK_BREAK, blockListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.BLOCK_DAMAGE, blockListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.BLOCK_IGNITE, blockListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.LEAVES_DECAY, blockListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.BLOCK_BURN, blockListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.BLOCK_FROMTO, blockListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.SIGN_CHANGE, blockListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.ENTITY_EXPLODE, entityListener, Priority.Monitor, this);
pm.registerEvent(Event.Type.ENTITY_DEATH, entityListener, Priority.Monitor, this);
// These events are used for Super Sticks
// Moved to playerListener. God help us. - N3X15
//pm.registerEvent(Event.Type.PLAYER_INTERACT, stickListener, Priority.Low, this);
pm.registerEvent(Event.Type.BLOCK_PLACE, stickListener, Priority.Low, this);
BBCommand bbc = new BBCommand(this);
bbc.registerExecutor("version", new VersionCommand(this));
bbc.registerExecutor("update", new UpdateCommand(this));