From ff186d5d9ddfa216b53f58e446414f374ec29b83 Mon Sep 17 00:00:00 2001 From: GJ Date: Wed, 16 Jan 2013 16:47:04 -0500 Subject: [PATCH] Make our StructureGrowEvent only care about player-planted trees. --- .../java/com/gmail/nossr50/listeners/WorldListener.java | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/main/java/com/gmail/nossr50/listeners/WorldListener.java b/src/main/java/com/gmail/nossr50/listeners/WorldListener.java index 71258fac3..8e258b1d3 100644 --- a/src/main/java/com/gmail/nossr50/listeners/WorldListener.java +++ b/src/main/java/com/gmail/nossr50/listeners/WorldListener.java @@ -2,7 +2,6 @@ package com.gmail.nossr50.listeners; import java.io.File; import java.util.ArrayList; -import java.util.List; import org.bukkit.TreeType; import org.bukkit.block.BlockState; @@ -29,10 +28,10 @@ public class WorldListener implements Listener { return; } - List blocks = event.getBlocks(); - - for (BlockState block : blocks) { - mcMMO.placeStore.setFalse(block.getBlock()); + if (mcMMO.placeStore.isTrue(event.getLocation().getBlock())) { + for (BlockState block : event.getBlocks()) { + mcMMO.placeStore.setFalse(block.getBlock()); + } } }