mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-22 21:20:06 +00:00
Backport: Only break one block when sneaking (#65)
* only break one block on shift * sportless Signed-off-by: NexusNull <[email protected]> * fixes https://github.com/GTNewHorizons/TinkersConstruct/pull/65/files/41a1ecea30cb0506d068da30c16fc27dcf64550f#r1071818922 Signed-off-by: NexusNull <[email protected]> Signed-off-by: NexusNull <[email protected]>
This commit is contained in:
1 parent
bb87654862
commit
54e24a25f4
1 file changed
+2
@@ -29,6 +29,8 @@ public abstract class AOEHarvestTool extends HarvestTool {
|
||||
NBTTagCompound toolTags = stack.getTagCompound().getCompoundTag("InfiTool");
|
||||
if (toolTags == null || toolTags.getBoolean("Broken")) return super.onBlockStartBreak(stack, x, y, z, player);
|
||||
|
||||
if (player.isSneaking()) return super.onBlockStartBreak(stack, x, y, z, player);
|
||||
|
||||
MovingObjectPosition mop = AbilityHelper.raytraceFromEntity(player.worldObj, player, false, 4.5d);
|
||||
if (mop == null) return super.onBlockStartBreak(stack, x, y, z, player);
|
||||
int sideHit = mop.sideHit;
|
||||
|
||||
Reference in new issue
Block a user