--- miscJava/bukkit-minecraft-plugins/HoerupUtils/src/dk/thoerup/bukkit/hoeruputils/HoerupUtilsPlugin.java 2011/06/20 20:10:41 1521 +++ miscJava/bukkit-minecraft-plugins/HoerupUtils/src/dk/thoerup/bukkit/hoeruputils/HoerupUtilsPlugin.java 2011/08/07 20:25:13 1586 @@ -6,6 +6,7 @@ import org.bukkit.plugin.PluginManager; import org.bukkit.plugin.java.JavaPlugin; +import dk.thoerup.bukkit.hoeruputils.secretdoor.DoorBlockListener; import dk.thoerup.bukkit.hoeruputils.web.MessageListener; import dk.thoerup.bukkit.hoeruputils.web.StatusListener; @@ -31,7 +32,7 @@ getCommand("stoner").setExecutor( new StonerCommand() ); getCommand("boom").setExecutor( new BoomCommand(this) ); getCommand("spawn").setExecutor( new SpawnCommand() ); - getCommand("superminer").setExecutor( new SuperminerCommand() ); + getCommand("tp").setExecutor( new TeleportCommand() ); PluginManager pm = getServer().getPluginManager(); pm.registerEvent(Event.Type.PLAYER_RESPAWN, new RespawnHandler(this), Priority.Normal, this); @@ -46,6 +47,22 @@ pm.registerEvent(Event.Type.BLOCK_DAMAGE, powerMiner, Priority.Normal, this); pm.registerEvent(Event.Type.PLAYER_QUIT, powerMiner.getPlayerQuitListener(), Priority.Normal, this); getCommand("powerminer").setExecutor(powerMiner); + + + SuperMiner superMiner = new SuperMiner(); + pm.registerEvent(Event.Type.BLOCK_DAMAGE, superMiner, Priority.Normal, this); + pm.registerEvent(Event.Type.PLAYER_QUIT, superMiner.getPlayerQuitListener(), Priority.Normal, this); + getCommand("superminer").setExecutor(superMiner); + + pm.registerEvent(Event.Type.PROJECTILE_HIT, new ExplosiveSnowballs(), Priority.Normal, this); + + + DoorBlockListener secretDoor = new DoorBlockListener(this); + pm.registerEvent(Event.Type.BLOCK_BREAK, secretDoor, Priority.Normal, this); + pm.registerEvent(Event.Type.SIGN_CHANGE, secretDoor, Priority.Normal, this); + pm.registerEvent(Event.Type.REDSTONE_CHANGE, secretDoor, Priority.Normal, this); + pm.registerEvent(Event.Type.PLAYER_INTERACT, secretDoor.getPlayerListener(), Priority.Normal, this); + } }