summaryrefslogtreecommitdiffstats
path: root/src/Simulator/RedstoneSimulator.h
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2013-12-14 03:40:54 +0100
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2013-12-14 03:40:54 +0100
commit0aeece7fdaccc8f20e96f9560c4f4c1b5a6bc5cc (patch)
tree44d1bcade3ba52a46423d7e04c094e6ec8255ad5 /src/Simulator/RedstoneSimulator.h
parentGroups.ini and Users.ini are now generated (diff)
downloadcuberite-0aeece7fdaccc8f20e96f9560c4f4c1b5a6bc5cc.tar
cuberite-0aeece7fdaccc8f20e96f9560c4f4c1b5a6bc5cc.tar.gz
cuberite-0aeece7fdaccc8f20e96f9560c4f4c1b5a6bc5cc.tar.bz2
cuberite-0aeece7fdaccc8f20e96f9560c4f4c1b5a6bc5cc.tar.lz
cuberite-0aeece7fdaccc8f20e96f9560c4f4c1b5a6bc5cc.tar.xz
cuberite-0aeece7fdaccc8f20e96f9560c4f4c1b5a6bc5cc.tar.zst
cuberite-0aeece7fdaccc8f20e96f9560c4f4c1b5a6bc5cc.zip
Diffstat (limited to '')
-rw-r--r--src/Simulator/RedstoneSimulator.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/Simulator/RedstoneSimulator.h b/src/Simulator/RedstoneSimulator.h
index 7c1fd62e8..23ac510fc 100644
--- a/src/Simulator/RedstoneSimulator.h
+++ b/src/Simulator/RedstoneSimulator.h
@@ -127,7 +127,11 @@ private:
void SetAllDirsAsPowered(int a_BlockX, int a_BlockY, int a_BlockZ, BLOCKTYPE a_SourceBlock);
/// <summary>Returns if a coordinate is powered or linked powered</summary>
- bool AreCoordsPowered(int a_BlockX, int a_BlockY, int a_BlockZ);
+ bool AreCoordsPowered(int a_BlockX, int a_BlockY, int a_BlockZ) { return AreCoordsDirectlyPowered(a_BlockX, a_BlockY, a_BlockZ) || AreCoordsLinkedPowered(a_BlockX, a_BlockY, a_BlockZ); }
+ /// <summary>Returns if a coordinate is in the directly powered blocks list</summary>
+ bool AreCoordsDirectlyPowered(int a_BlockX, int a_BlockY, int a_BlockZ);
+ /// <summary>Returns if a coordinate is in the indirectly powered blocks list</summary>
+ bool AreCoordsLinkedPowered(int a_BlockX, int a_BlockY, int a_BlockZ);
/// <summary>Returns if a coordinate was marked as simulated (for blocks toggleable by players)</summary>
bool AreCoordsSimulated(int a_BlockX, int a_BlockY, int a_BlockZ, bool IsCurrentStatePowered);
/// <summary>Returns if a repeater is powered</summary>