Skip to content

Commit 5ea9380

Browse files
committed
Fix neighbouring redstone clocks making each other faster
1 parent de64946 commit 5ea9380

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/main/java/com/fouristhenumber/utilitiesinexcess/common/blocks/BlockRedstoneClock.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,12 @@ public int isProvidingWeakPower(IBlockAccess world, int x, int y, int z, int sid
5050
@Override
5151
public void onNeighborBlockChange(World world, int x, int y, int z, Block neighbor) {
5252
super.onNeighborBlockChange(world, x, y, z, neighbor);
53+
54+
if(neighbor instanceof BlockRedstoneClock) {
55+
// Don't let neighbouring clocks trigger updates to each other
56+
return;
57+
}
58+
5359
TileEntity te = world.getTileEntity(x, y, z);
5460
if (te instanceof TileEntityRedstoneClock) {
5561
((TileEntityRedstoneClock) te).onInputChanged();

0 commit comments

Comments
 (0)