diff options
author | Tiger Wang <ziwei.tiger@hotmail.co.uk> | 2014-05-05 16:43:45 +0200 |
---|---|---|
committer | Tiger Wang <ziwei.tiger@hotmail.co.uk> | 2014-05-05 16:43:45 +0200 |
commit | bde40af40664e0b526fed8224c1f00531c5610c6 (patch) | |
tree | 2972fd815f11dbd852c17fa0c13fbf7cb70f1358 /src | |
parent | Merge pull request #956 from mc-server/redstoneimprovements (diff) | |
download | cuberite-bde40af40664e0b526fed8224c1f00531c5610c6.tar cuberite-bde40af40664e0b526fed8224c1f00531c5610c6.tar.gz cuberite-bde40af40664e0b526fed8224c1f00531c5610c6.tar.bz2 cuberite-bde40af40664e0b526fed8224c1f00531c5610c6.tar.lz cuberite-bde40af40664e0b526fed8224c1f00531c5610c6.tar.xz cuberite-bde40af40664e0b526fed8224c1f00531c5610c6.tar.zst cuberite-bde40af40664e0b526fed8224c1f00531c5610c6.zip |
Diffstat (limited to '')
-rw-r--r-- | src/Simulator/IncrementalRedstoneSimulator.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/Simulator/IncrementalRedstoneSimulator.cpp b/src/Simulator/IncrementalRedstoneSimulator.cpp index 3e8a4dec0..f12bd6d49 100644 --- a/src/Simulator/IncrementalRedstoneSimulator.cpp +++ b/src/Simulator/IncrementalRedstoneSimulator.cpp @@ -444,7 +444,7 @@ void cIncrementalRedstoneSimulator::HandleRedstoneLever(int a_RelBlockX, int a_R SetAllDirsAsPowered(a_RelBlockX, a_RelBlockY, a_RelBlockZ); NIBBLETYPE Dir = cBlockLeverHandler::BlockMetaDataToBlockFace(Meta); - switch (Dir) + switch (Dir) // Now, flip the direction into the type used by SetBlockLinkedPowered() { case BLOCK_FACE_YP: case BLOCK_FACE_XP: @@ -510,9 +510,10 @@ void cIncrementalRedstoneSimulator::HandleRedstoneButton(int a_RelBlockX, int a_ NIBBLETYPE Meta = m_Chunk->GetMeta(a_RelBlockX, a_RelBlockY, a_RelBlockZ); if (IsButtonOn(Meta)) { - SetAllDirsAsPowered(a_RelBlockX, a_RelBlockY, a_RelBlockZ);NIBBLETYPE Dir = cBlockButtonHandler::BlockMetaDataToBlockFace(Meta); - - switch (Dir) + SetAllDirsAsPowered(a_RelBlockX, a_RelBlockY, a_RelBlockZ); + + NIBBLETYPE Dir = cBlockButtonHandler::BlockMetaDataToBlockFace(Meta); + switch (Dir) // Now, flip the direction into the type used by SetBlockLinkedPowered() { case BLOCK_FACE_XP: case BLOCK_FACE_ZP: |