Skip to content

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also .

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also .
  • 2 commits
  • 3 files changed
  • 0 commit comments
  • 1 contributor
Commits on Mar 28, 2012
@Tux2 More mobs d9d2517
Commits on Jun 23, 2012
@Tux2 Fixed mcMMO beserk unlimited spawner issue e55cdd1
Showing with 10 additions and 2 deletions.
  1. +1 −1 src/plugin.yml
  2. +1 −1 src/tux2/MonsterBox/MonsterBox.java
  3. +8 −0 src/tux2/MonsterBox/MonsterBoxBlockListener.java
View
2 src/plugin.yml
@@ -1,6 +1,6 @@
name: MonsterBox
main: tux2.MonsterBox.MonsterBox
-version: 0.8
+version: 0.8.2
commands:
mbox:
description: Sets the monster spawner you are looking at to the specified mob type.
View
2 src/tux2/MonsterBox/MonsterBox.java
@@ -618,7 +618,7 @@ public void loadDisabledSpawners() {
}
}catch (Exception e) {
// If it doesn't work, no great loss!
- e.printStackTrace();
+ //e.printStackTrace();
}
}
}
View
8 src/tux2/MonsterBox/MonsterBoxBlockListener.java
@@ -56,13 +56,21 @@ public void onBlockBreak(BlockBreakEvent event) {
event.getPlayer().sendMessage(ChatColor.DARK_GREEN + "You just broke a " + ChatColor.RED + monster.toLowerCase() + ChatColor.DARK_GREEN + " spawner.");
}
}
+ //fix the beserk thingy that some players have been reporting.
+ boolean mcmmofix = false;
if(plugin.hasPermissions(event.getPlayer(), "monsterbox.drops")) {
ItemStack mobstack = new ItemStack(Material.MOB_SPAWNER, 1);
event.getBlock().getWorld().dropItemNaturally(event.getBlock().getLocation(), mobstack);
+ mcmmofix = true;
}
if(!nodrops && stringmobs.containsKey(monster) && plugin.hasPermissions(event.getPlayer(), "monsterbox.dropegg." + monster.toLowerCase())) {
ItemStack eggstack = new ItemStack(383, 1, theSpawner.getSpawnedType().getTypeId());
event.getBlock().getWorld().dropItemNaturally(event.getBlock().getLocation(), eggstack);
+ mcmmofix = true;
+ }
+ //If we dropped something, let's break the spawner
+ if(mcmmofix) {
+ event.getBlock().setType(Material.AIR);
}
}catch (Exception e) {
}

No commit comments for this range

Something went wrong with that request. Please try again.