Examples of dropBlockAsItem()


Examples of net.minecraft.block.Block.dropBlockAsItem()

          block2.onBlockDestroyedByPlayer(player.worldObj, coord.xCoord, coord.yCoord, coord.zCoord, meta);
          player.worldObj.playAuxSFXAtEntity(null, 2001, coord.xCoord, coord.yCoord, coord.zCoord, meta << 12);
          player.worldObj.setBlockToAir(coord.xCoord, coord.yCoord, coord.zCoord);
          block2.breakBlock(player.worldObj, coord.xCoord, coord.yCoord, coord.zCoord, block, meta);
          block2.dropBlockAsItem(player.worldObj, coord.xCoord, coord.yCoord, coord.zCoord, meta, 0);

          setEnergy(itemstack, getEnergy(itemstack) - (ENERGY_USAGE*getEfficiency(itemstack)));
        }
      }
    }
 
View Full Code Here

Examples of net.minecraft.block.Block.dropBlockAsItem()

          //And if it didn't die from the attack, break the block
          worldObj.playAuxSFXAtEntity(null, 2001, x, y, z, Block.getIdFromBlock(blockHit) + (meta << 12));         
         
          if(!worldObj.isRemote)
          { 
            blockHit.dropBlockAsItem(worldObj, x, y, z, meta, 1);   
            worldObj.setBlockToAir(x, y, z);
          }
        }
        else
        {
View Full Code Here

Examples of net.minecraft.block.Block.dropBlockAsItem()

        if (displacements.containsKey(block))
        {
            if (displacements.get(block))
            {
                block.dropBlockAsItem(world, x, y, z, world.getBlockMetadata(x, y, z), 0);
                return true;
            }
            return false;
        }
View Full Code Here

Examples of net.minecraft.block.Block.dropBlockAsItem()

        }

        int density = getDensity(world, x, y, z);
        if (density == Integer.MAX_VALUE)
        {
           block.dropBlockAsItem(world, x, y, z, world.getBlockMetadata(x, y, z), 0);
           return true;
        }
       
        if (this.density > density)
        {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.