From a49a35834968612e3c2cc30495459a0d1f04b6cf Mon Sep 17 00:00:00 2001 From: Nathan Adams Date: Tue, 11 Oct 2011 00:37:39 +0100 Subject: [PATCH] Changing the blockList on explosions now correctly updates which blocks are changed --- src/main/java/net/minecraft/server/Explosion.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/main/java/net/minecraft/server/Explosion.java b/src/main/java/net/minecraft/server/Explosion.java index 4db1a31a1a..67fdefdd21 100644 --- a/src/main/java/net/minecraft/server/Explosion.java +++ b/src/main/java/net/minecraft/server/Explosion.java @@ -194,6 +194,15 @@ public class Explosion { EntityExplodeEvent event = new EntityExplodeEvent(explode, location, blockList); this.world.getServer().getPluginManager().callEvent(event); + + arraylist.clear(); + blocks.clear(); + + for (org.bukkit.block.Block block : event.blockList()) { + ChunkCoordinates coords = new ChunkCoordinates(block.getX(), block.getY(), block.getZ()); + arraylist.add(coords); + blocks.add(coords); + } if (event.isCancelled()) { this.wasCanceled = true;