From f35060e8b518cac8521528a7398be7a095ccc108 Mon Sep 17 00:00:00 2001 From: bibo38 Date: Thu, 5 Nov 2015 14:50:43 +0100 Subject: Replaced the usage of pistonMeta with a direction vector to allow better meta value abstraction --- src/Blocks/BlockPiston.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/Blocks/BlockPiston.h') diff --git a/src/Blocks/BlockPiston.h b/src/Blocks/BlockPiston.h index 41ef79aa6..b08ca5fee 100644 --- a/src/Blocks/BlockPiston.h +++ b/src/Blocks/BlockPiston.h @@ -81,6 +81,8 @@ public: } } + static Vector3i GetDirectionVec(int a_PistonMeta); + static void ExtendPiston(int a_BlockX, int a_BlockY, int a_BlockZ, cWorld * a_World); static void RetractPiston(int a_BlockX, int a_BlockY, int a_BlockZ, cWorld * a_World); @@ -157,7 +159,7 @@ private: /** Tries to push a block and increases the pushed blocks variable. Returns true if the block is pushable */ static bool CanPushBlock( int a_BlockX, int a_BlockY, int a_BlockZ, cWorld * a_World, bool a_RequirePushable, - std::unordered_set> & a_BlocksPushed, NIBBLETYPE a_PistonMeta + std::unordered_set> & a_BlocksPushed, const Vector3i & a_PushDir ); } ; -- cgit v1.2.3