Class CandleBlock


public class CandleBlock extends ClusterBlock
  • Constructor Details

    • CandleBlock

      public CandleBlock(int id, int metaDropped, String name, String texture)
  • Method Details

    • idDropped

      public int idDropped(int par1, Random rand, int par3)
      Description copied from class: Block
      Returns the ID of the items to drop on destruction.
      Overrides:
      idDropped in class Block
    • damageDropped

      public int damageDropped(int meta)
      Description copied from class: Block
      Determines the damage on the item the block drops. Used in cloth and wood.
      Overrides:
      damageDropped in class Block
    • canPlaceBlockAt

      public boolean canPlaceBlockAt(World world, int x, int y, int z)
      Description copied from class: Block
      Checks to see if its valid to put this block at the specified coordinates. Args: world, x, y, z
      Overrides:
      canPlaceBlockAt in class Block
    • getBlockBoundsFromPoolBasedOnState

      public AxisAlignedBB getBlockBoundsFromPoolBasedOnState(IBlockAccess blockAccess, int x, int y, int z)
      Overrides:
      getBlockBoundsFromPoolBasedOnState in class Block
    • getSelectedBoundingBoxFromPool

      @Environment(CLIENT) public AxisAlignedBB getSelectedBoundingBoxFromPool(World world, MovingObjectPosition hit)
      Description copied from class: Block
      Replaces vanilla call in RenderGlobal to provide ray trace info so specific portions of the block can be highlighted as selected
      Overrides:
      getSelectedBoundingBoxFromPool in class Block
    • collisionRayTrace

      public MovingObjectPosition collisionRayTrace(World world, int i, int j, int k, Vec3 startRay, Vec3 endRay)
      Overrides:
      collisionRayTrace in class Block
    • getLightValue

      public int getLightValue(IBlockAccess blockAccess, int x, int y, int z)
      Overrides:
      getLightValue in class Block
    • getCanBeSetOnFireDirectly

      public boolean getCanBeSetOnFireDirectly(IBlockAccess blockAccess, int x, int y, int z)
      Description copied from class: Block
      Whether the block itself can be set on fire, rather than a neighboring block being set to a fire block
      Overrides:
      getCanBeSetOnFireDirectly in class Block
    • setOnFireDirectly

      public boolean setOnFireDirectly(World world, int x, int y, int z)
      Overrides:
      setOnFireDirectly in class Block
    • getCanBlockLightItemOnFire

      public boolean getCanBlockLightItemOnFire(IBlockAccess blockAccess, int x, int y, int z)
      Overrides:
      getCanBlockLightItemOnFire in class Block
    • isLit

      public boolean isLit(IBlockAccess blockAccess, int x, int y, int z)
    • setLit

      public void setLit(World world, int x, int y, int z, boolean isLit)
    • setLit

      public int setLit(int meta, boolean isLit)
    • isOnSoulforge

      public boolean isOnSoulforge(IBlockAccess access, int i, int j, int k)
      Checks if candles are resting on top of a Soulforge
    • getRotationForDisplay

      public int getRotationForDisplay(IBlockAccess access, int i, int j, int k)
      Determines rotation value for candles
    • registerIcons

      @Environment(CLIENT) public void registerIcons(IconRegister register)
      Description copied from class: Block
      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
    • getBlockTexture

      @Environment(CLIENT) public Icon getBlockTexture(IBlockAccess blockAccess, int x, int y, int z, int side)
      Description copied from class: Block
      Retrieves the block texture to use based on the display side. Args: iBlockAccess, x, y, z, side
      Overrides:
      getBlockTexture in class Block
    • randomDisplayTick

      @Environment(CLIENT) public void randomDisplayTick(World world, int x, int y, int z, Random rand)
      A randomly called display update to be able to add particles or other items for display
      Overrides:
      randomDisplayTick in class Block
    • renderBlock

      @Environment(CLIENT) public boolean renderBlock(RenderBlocks render, int x, int y, int z)
      Overrides:
      renderBlock in class Block