1
0

Fix repeater unpowering

This commit is contained in:
Tiger Wang 2014-12-18 00:22:46 +00:00
parent 5dfb094d6a
commit dd1df3b6f7

View File

@ -2074,9 +2074,11 @@ void cIncrementalRedstoneSimulator::SetSourceUnpowered(int a_RelSourceX, int a_R
for (const auto & itr : BlocksPotentiallyUnpowered)
{
if (!AreCoordsPowered(itr.x, itr.y, itr.z))
auto Neighbour = a_Chunk->GetRelNeighborChunk(itr.x, itr.z);
if (!AreCoordsPowered(itr.x, itr.y, itr.z) && (Neighbour->GetBlock(itr) != E_BLOCK_REDSTONE_REPEATER_ON))
{
SetSourceUnpowered(itr.x, itr.y, itr.z, a_Chunk->GetRelNeighborChunk(itr.x, itr.z));
// Repeaters time themselves with regards to unpowering; ensure we don't do it for them
SetSourceUnpowered(itr.x, itr.y, itr.z, Neighbour);
}
}
}