Merge branch 'master' into 1.15
This commit is contained in:
commit
43c9a8a886
1 file changed
+5
-1
@@ -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;
|
||||
|
||||
Reference in new issue
Block a user