fixed bug preventing removal of gates without from location
This commit is contained in:
1 parent
6bb50672a5
commit
a474963666
1 file changed
+5
-3
@@ -110,11 +110,13 @@ public class Gate {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void close() {
|
public void close()
|
||||||
|
{
|
||||||
|
if (from != null)
|
||||||
|
{
|
||||||
Set<Block> blocks = FloodUtil.getGateFrameBlocks(from.getBlock());
|
Set<Block> blocks = FloodUtil.getGateFrameBlocks(from.getBlock());
|
||||||
|
|
||||||
// Uncomment lines below to have the old Portal open functionality back.
|
for (Block block : blocks)
|
||||||
for (Block block : blocks) {
|
|
||||||
block.setType(Material.AIR);
|
block.setType(Material.AIR);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user