Fixed cpw's derp in the PlayerInteractEvent logic.
This commit is contained in:
parent
4cfffe784e
commit
dd8893a65c
|
@ -180,9 +180,9 @@
|
||||||
+ Block block = Block.blocksList[var11];
|
+ Block block = Block.blocksList[var11];
|
||||||
+ boolean result = false;
|
+ boolean result = false;
|
||||||
+
|
+
|
||||||
+ if (block != null)
|
+ if (block != null && (!par1EntityPlayer.isSneaking() || par1EntityPlayer.getHeldItem() == null))
|
||||||
+ {
|
+ {
|
||||||
+ if ((!par1EntityPlayer.isSneaking() || par1EntityPlayer.getHeldItem() == null) && event.useBlock != Event.Result.DENY)
|
+ if (event.useBlock != Event.Result.DENY)
|
||||||
+ {
|
+ {
|
||||||
+ result = block.onBlockActivated(par2World, par4, par5, par6, par1EntityPlayer, par7, par8, par9, par10);
|
+ result = block.onBlockActivated(par2World, par4, par5, par6, par1EntityPlayer, par7, par8, par9, par10);
|
||||||
+ }
|
+ }
|
||||||
|
|
Loading…
Reference in New Issue