summaryrefslogtreecommitdiffstats
path: root/src/Defines.h
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2014-02-02 22:48:21 +0100
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2014-02-02 22:48:21 +0100
commit0f67f80c6e60b2696bf94ee91330cdc0cefde3fa (patch)
treece3d4d45a1a0fe077fe6b5145c4926188b213352 /src/Defines.h
parentRevert "Added LOGREPLACELINE for line replacement" (diff)
downloadcuberite-0f67f80c6e60b2696bf94ee91330cdc0cefde3fa.tar
cuberite-0f67f80c6e60b2696bf94ee91330cdc0cefde3fa.tar.gz
cuberite-0f67f80c6e60b2696bf94ee91330cdc0cefde3fa.tar.bz2
cuberite-0f67f80c6e60b2696bf94ee91330cdc0cefde3fa.tar.lz
cuberite-0f67f80c6e60b2696bf94ee91330cdc0cefde3fa.tar.xz
cuberite-0f67f80c6e60b2696bf94ee91330cdc0cefde3fa.tar.zst
cuberite-0f67f80c6e60b2696bf94ee91330cdc0cefde3fa.zip
Diffstat (limited to '')
-rw-r--r--src/Defines.h20
1 files changed, 11 insertions, 9 deletions
diff --git a/src/Defines.h b/src/Defines.h
index b3dbcc93e..5b868b2e5 100644
--- a/src/Defines.h
+++ b/src/Defines.h
@@ -254,16 +254,18 @@ inline bool IsValidItem(int a_ItemType)
-inline bool IsBlockWater(BLOCKTYPE a_BlockType, bool a_IncludeFrozenWater = false)
+inline bool IsBlockWater(BLOCKTYPE a_BlockType)
{
- if (a_IncludeFrozenWater)
- {
- return ((a_BlockType == E_BLOCK_WATER) || (a_BlockType == E_BLOCK_STATIONARY_WATER) || (a_BlockType == E_BLOCK_ICE));
- }
- else
- {
- return ((a_BlockType == E_BLOCK_WATER) || (a_BlockType == E_BLOCK_STATIONARY_WATER));
- }
+ return ((a_BlockType == E_BLOCK_WATER) || (a_BlockType == E_BLOCK_STATIONARY_WATER));
+}
+
+
+
+
+
+inline bool IsBlockWaterOrIce(BLOCKTYPE a_BlockType)
+{
+ return (IsBlockWater(a_BlockType) || (a_BlockType == E_BLOCK_ICE));
}