summaryrefslogtreecommitdiffstats
path: root/source/Piston.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'source/Piston.cpp')
-rw-r--r--source/Piston.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/source/Piston.cpp b/source/Piston.cpp
index f4244d177..b5fda1600 100644
--- a/source/Piston.cpp
+++ b/source/Piston.cpp
@@ -270,7 +270,13 @@ bool cPiston::CanPull(BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta)
return false;
}
}
- return CanPush(a_BlockType, a_BlockMeta) || CanBreakPush(a_BlockType, a_BlockMeta);
+
+ if (CanBreakPush(a_BlockType, a_BlockMeta))
+ {
+ return false; // CanBreakPush returns true, but we need false to prevent pulling
+ }
+
+ return CanPush(a_BlockType, a_BlockMeta);
}