diff options
author | feildmaster <admin@feildmaster.com> | 2012-04-02 15:44:19 -0500 |
---|---|---|
committer | feildmaster <admin@feildmaster.com> | 2012-04-02 16:32:54 -0500 |
commit | bad3979b8f528d3df96a97adc0e352b9025d82f0 (patch) | |
tree | e79e088004a15a3776d1268a4f5fe88a5759cd10 | |
parent | 470d9f9e1d3cd1234d19607f1b68e4a918657533 (diff) | |
download | craftbukkit-bad3979b8f528d3df96a97adc0e352b9025d82f0.tar craftbukkit-bad3979b8f528d3df96a97adc0e352b9025d82f0.tar.gz craftbukkit-bad3979b8f528d3df96a97adc0e352b9025d82f0.tar.lz craftbukkit-bad3979b8f528d3df96a97adc0e352b9025d82f0.tar.xz craftbukkit-bad3979b8f528d3df96a97adc0e352b9025d82f0.zip |
Make EntityCreatePortalEvent block list Unmodifiable.
-rw-r--r-- | src/main/java/net/minecraft/server/EntityEnderDragon.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/net/minecraft/server/EntityEnderDragon.java b/src/main/java/net/minecraft/server/EntityEnderDragon.java index 198c108f..f8aeae07 100644 --- a/src/main/java/net/minecraft/server/EntityEnderDragon.java +++ b/src/main/java/net/minecraft/server/EntityEnderDragon.java @@ -574,8 +574,7 @@ public class EntityEnderDragon extends EntityComplex { byte b1 = 4; // CraftBukkit start - Replace any "this.world" in the following with just "world"! - org.bukkit.event.entity.EntityCreatePortalEvent event = new org.bukkit.event.entity.EntityCreatePortalEvent((org.bukkit.entity.LivingEntity) this.getBukkitEntity(), new ArrayList<BlockState>(), org.bukkit.PortalType.ENDER); - org.bukkit.craftbukkit.util.BlockStateListPopulator world = new org.bukkit.craftbukkit.util.BlockStateListPopulator(this.world.getWorld(), event.getBlocks()); + org.bukkit.craftbukkit.util.BlockStateListPopulator world = new org.bukkit.craftbukkit.util.BlockStateListPopulator(this.world.getWorld()); for (int k = b0 - 1; k <= b0 + 32; ++k) { for (int l = i - b1; l <= i + b1; ++l) { @@ -611,6 +610,7 @@ public class EntityEnderDragon extends EntityComplex { world.setTypeId(i, b0 + 3, j, Block.BEDROCK.id); world.setTypeId(i, b0 + 4, j, Block.DRAGON_EGG.id); + org.bukkit.event.entity.EntityCreatePortalEvent event = new org.bukkit.event.entity.EntityCreatePortalEvent((org.bukkit.entity.LivingEntity) this.getBukkitEntity(), java.util.Collections.unmodifiableList(world.getList()), org.bukkit.PortalType.ENDER); this.world.getServer().getPluginManager().callEvent(event); if (!event.isCancelled()) { |