summaryrefslogtreecommitdiffstats
path: root/src/Defines.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Defines.cpp')
-rw-r--r--src/Defines.cpp13
1 files changed, 3 insertions, 10 deletions
diff --git a/src/Defines.cpp b/src/Defines.cpp
index 4e0ad775a..a016dba92 100644
--- a/src/Defines.cpp
+++ b/src/Defines.cpp
@@ -160,17 +160,10 @@ AString BlockFaceToString(eBlockFace a_BlockFace)
bool IsValidBlock(int a_BlockType)
{
- if (
- (
- (a_BlockType > -1) &&
- (a_BlockType <= E_BLOCK_MAX_TYPE_ID)
- ) ||
+ return (
+ ((a_BlockType > -1) && (a_BlockType <= E_BLOCK_MAX_TYPE_ID)) ||
(a_BlockType == 255) // the blocks 253-254 don't exist yet -> https://minecraft.gamepedia.com/Data_values#Block_IDs
- )
- {
- return true;
- }
- return false;
+ );
}