Fixed cpw's derp in the PlayerInteractEvent logic.

This commit is contained in:
LexManos 2012-12-20 15:02:06 -08:00
parent 4cfffe784e
commit dd8893a65c

View file

@ -180,9 +180,9 @@
+ Block block = Block.blocksList[var11];
+ 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);
+ }