From 331d012849ce3c0b992c6e9f0489108ffe413ef6 Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Mon, 22 Oct 2012 18:04:15 +0000 Subject: Slight formatting tuneup to the previous commit. git-svn-id: http://mc-server.googlecode.com/svn/trunk@1003 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/Blocks/BlockVine.h | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'source/Blocks') diff --git a/source/Blocks/BlockVine.h b/source/Blocks/BlockVine.h index 01aecbe0d..8ad2f4b35 100644 --- a/source/Blocks/BlockVine.h +++ b/source/Blocks/BlockVine.h @@ -17,6 +17,7 @@ public: { } + virtual void PlaceBlock(cWorld * a_World, cPlayer * a_Player, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ, char a_Dir) override { a_World->SetBlock(a_BlockX, a_BlockY, a_BlockZ, m_BlockType, cVine::DirectionToMetaData(a_Dir)); @@ -27,17 +28,18 @@ public: virtual bool CanBePlacedAt(cWorld * a_World, int a_BlockX, int a_BlockY, int a_BlockZ, char a_Dir) override { if ( - (a_World->GetBlock( a_BlockX, a_BlockY+1, a_BlockZ ) == E_BLOCK_VINES) && - (cVine::MetaDataToDirection(a_World->GetBlockMeta( a_BlockX, a_BlockY+1, a_BlockZ )) == a_Dir) + (a_World->GetBlock( a_BlockX, a_BlockY + 1, a_BlockZ ) == E_BLOCK_VINES) && + (cVine::MetaDataToDirection(a_World->GetBlockMeta( a_BlockX, a_BlockY + 1, a_BlockZ )) == a_Dir) ) { return true; } - if ((a_World->GetBlock( a_BlockX, a_BlockY+1, a_BlockZ ) != E_BLOCK_AIR)) + if ((a_World->GetBlock( a_BlockX, a_BlockY + 1, a_BlockZ ) != E_BLOCK_AIR)) { AddDirection( a_BlockX, a_BlockY, a_BlockZ, a_Dir, true ); - if(a_World->GetBlock( a_BlockX, a_BlockY, a_BlockZ ) == E_BLOCK_AIR){ + if (a_World->GetBlock( a_BlockX, a_BlockY, a_BlockZ ) == E_BLOCK_AIR) + { AddDirection( a_BlockX, a_BlockY, a_BlockZ, a_Dir, false ); a_World->FastSetBlock( a_BlockX, a_BlockY, a_BlockZ, E_BLOCK_VINES, 0); } @@ -56,6 +58,7 @@ public: return CanBePlacedAt(a_World, a_BlockX, a_BlockY, a_BlockZ, Dir); } + virtual bool DoesIgnoreBuildCollision(void) override { return true; -- cgit v1.2.3