diff --git a/src/main/java/carpet/helpers/RedstoneWireTurbo.java b/src/main/java/carpet/helpers/RedstoneWireTurbo.java index 2fe9407d..d562b0f1 100644 --- a/src/main/java/carpet/helpers/RedstoneWireTurbo.java +++ b/src/main/java/carpet/helpers/RedstoneWireTurbo.java @@ -9,6 +9,7 @@ import java.util.concurrent.ThreadLocalRandom; import carpet.fakes.RedstoneWireBlockInterface; import net.minecraft.block.Block; +import net.minecraft.block.Blocks; import net.minecraft.block.RedstoneWireBlock; import net.minecraft.block.BlockState; import net.minecraft.util.math.BlockPos; @@ -905,7 +906,10 @@ public class RedstoneWireTurbo // Possible optimization: Don't commit state changes to the world until they // need to be known by some nearby non-redstone-wire block. state = state.with(RedstoneWireBlock.POWER, j); - worldIn.setBlockState(upd.self, state, 2); + // [gnembon] added state check cause other things in the tick may have popped it up already + // https://github.com/gnembon/fabric-carpet/issues/117 + if (worldIn.getBlockState(upd.self).getBlock() == Blocks.REDSTONE_WIRE) + worldIn.setBlockState(upd.self, state, 2); } return state;