Class BlockTNT

java.lang.Object
net.minecraft.src.Block
net.minecraft.src.BlockTNT

public class BlockTNT extends Block
  • Constructor Details

    • BlockTNT

      public BlockTNT(int par1)
  • Method Details

    • getIcon

      public Icon getIcon(int par1, int par2)
      From the specified side and block metadata retrieves the blocks texture. Args: side, metadata
      Overrides:
      getIcon in class Block
    • onBlockAdded

      public void onBlockAdded(World par1World, int par2, int par3, int par4)
      Called whenever the block is added into the world. Args: world, x, y, z
      Overrides:
      onBlockAdded in class Block
    • onNeighborBlockChange

      public void onNeighborBlockChange(World par1World, int par2, int par3, int par4, int par5)
      Lets the block know when one of its neighbor changes. Doesn't know which neighbor changed (coordinates passed are their own) Args: x, y, z, neighbor blockID
      Overrides:
      onNeighborBlockChange in class Block
    • quantityDropped

      public int quantityDropped(Random par1Random)
      Returns the quantity of items to drop on block destruction.
      Overrides:
      quantityDropped in class Block
    • onBlockDestroyedByExplosion

      public void onBlockDestroyedByExplosion(World par1World, int par2, int par3, int par4, Explosion par5Explosion)
      Called upon the block being destroyed by an explosion
      Overrides:
      onBlockDestroyedByExplosion in class Block
    • onDestroyedByFire

      public void onDestroyedByFire(World world, int i, int j, int k, int iFireAge, boolean bForcedFireSpread)
      Overrides:
      onDestroyedByFire in class Block
    • onBlockDestroyedByPlayer

      public void onBlockDestroyedByPlayer(World par1World, int par2, int par3, int par4, int par5)
      Called right before the block is destroyed by a player. Args: world, x, y, z, metaData
      Overrides:
      onBlockDestroyedByPlayer in class Block
    • primeTnt

      public void primeTnt(World par1World, int par2, int par3, int par4, int par5, EntityLivingBase par6EntityLivingBase)
      spawns the primed tnt and plays the fuse sound.
    • onBlockActivated

      public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer, int par6, float par7, float par8, float par9)
      Called upon block activation (right click on the block.)
      Overrides:
      onBlockActivated in class Block
    • onEntityCollidedWithBlock

      public void onEntityCollidedWithBlock(World par1World, int par2, int par3, int par4, Entity par5Entity)
      Triggered whenever an entity collides with this block (enters into the block). Args: world, x, y, z, entity
      Overrides:
      onEntityCollidedWithBlock in class Block
    • canDropFromExplosion

      public boolean canDropFromExplosion(Explosion par1Explosion)
      Return whether this block can drop from an explosion.
      Overrides:
      canDropFromExplosion in class Block
    • registerIcons

      public void registerIcons(IconRegister par1IconRegister)
      When this method is called, your block should register all the icons it needs with the given IconRegister. This is the only chance you get to register icons.
      Overrides:
      registerIcons in class Block