From e4a7164dd313e52c14af09b9bb0e1f695c425d83 Mon Sep 17 00:00:00 2001 From: Lixfel Date: Sat, 4 Jul 2020 09:21:26 +0200 Subject: [PATCH] Fix tile entitys --- BauSystem_15/src/de/steamwar/bausystem/world/Region_15.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/BauSystem_15/src/de/steamwar/bausystem/world/Region_15.java b/BauSystem_15/src/de/steamwar/bausystem/world/Region_15.java index 76588b8..6996193 100644 --- a/BauSystem_15/src/de/steamwar/bausystem/world/Region_15.java +++ b/BauSystem_15/src/de/steamwar/bausystem/world/Region_15.java @@ -46,12 +46,13 @@ public class Region_15 { BlockPosition blockPos = new BlockPosition(X, Y, Z); BaseBlock fullBlock = clipboard.getFullBlock(BlockVector3.at(X, Y, Z).subtract(v).add(clipboard.getRegion().getMinimumPoint())); Material replaceTo = BukkitAdapter.adapt(fullBlock.getBlockType()); + world.removeTileEntity(blockPos); if(replaceTo == null) world.setTypeAndData(blockPos, ((CraftBlockData)Material.AIR.createBlockData()).getState(), 1042); else world.setTypeAndData(new BlockPosition(X, Y, Z), ((CraftBlockData)replaceTo.createBlockData()).getState(), 1042); + world.getChunkProvider().flagDirty(blockPos); - //world.getChunkProvider().getLightEngine().a(blockPos); //TODO: Fix lightning issues without preventing shutdown } } }