From b65a22fc1f0e5e95be234d6d94388091f74704a9 Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Fri, 16 Nov 2012 16:03:56 +0000 Subject: Fixed boolean comparison. Don't compare booleans to false / true, use them directly. git-svn-id: http://mc-server.googlecode.com/svn/trunk@1048 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/Blocks/BlockVine.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source/Blocks') diff --git a/source/Blocks/BlockVine.h b/source/Blocks/BlockVine.h index cdef18520..791b01a79 100644 --- a/source/Blocks/BlockVine.h +++ b/source/Blocks/BlockVine.h @@ -36,11 +36,11 @@ public: } BLOCKTYPE TopBlock = a_World->GetBlock( a_BlockX, a_BlockY + 1, a_BlockZ); - if (g_BlockIsSolid[TopBlock] || TopBlock==E_BLOCK_LEAVES) + if (g_BlockIsSolid[TopBlock] || (TopBlock == E_BLOCK_LEAVES)) { AddDirection( a_BlockX, a_BlockY, a_BlockZ, a_Dir, true ); BLOCKTYPE BaseBlock = a_World->GetBlock( a_BlockX, a_BlockY, a_BlockZ); - if (g_BlockIsSolid[BaseBlock] == false && BaseBlock!=E_BLOCK_LEAVES) + if (!g_BlockIsSolid[BaseBlock] && (BaseBlock != E_BLOCK_LEAVES)) { AddDirection( a_BlockX, a_BlockY, a_BlockZ, a_Dir, false ); a_World->SetBlock( a_BlockX, a_BlockY, a_BlockZ, E_BLOCK_VINES, 0); @@ -50,7 +50,7 @@ public: AddDirection( a_BlockX, a_BlockY, a_BlockZ, a_Dir, true ); BLOCKTYPE BaseBlock = a_World->GetBlock( a_BlockX, a_BlockY, a_BlockZ); - return g_BlockIsSolid[BaseBlock] || BaseBlock==E_BLOCK_LEAVES; + return (g_BlockIsSolid[BaseBlock] || (BaseBlock == E_BLOCK_LEAVES)); } -- cgit v1.2.3