Class SlabBlock

java.lang.Object
net.minecraft.src.Block
api.block.blocks.SlabBlock
Direct Known Subclasses:
AttachedSlabBlock, BoneSlabBlock, CreeperOysterSlabBlock, FallingSlabBlock, RottenFleshSlabBlock, SolidSnowSlabBlock, SpiderEyeSlab, WickerSlabBlock, WoolSlabBlock

public abstract class SlabBlock extends Block
  • Constructor Details

    • SlabBlock

      public SlabBlock(int iBlockID, Material material)
  • Method Details

    • onBlockPlaced

      public int onBlockPlaced(World world, int i, int j, int k, int iFacing, float fClickX, float fClickY, float fClickZ, int iMetadata)
      Description copied from class: Block
      Called when a block is placed using its ItemBlock. Args: World, X, Y, Z, side, hitX, hitY, hitZ, block metadata
      Overrides:
      onBlockPlaced in class Block
    • getBlockBoundsFromPoolBasedOnState

      public AxisAlignedBB getBlockBoundsFromPoolBasedOnState(IBlockAccess blockAccess, int i, int j, int k)
      Overrides:
      getBlockBoundsFromPoolBasedOnState in class Block
    • isOpaqueCube

      public boolean isOpaqueCube()
      Description copied from class: Block
      // +++START EDIT+++ // ---END EDIT--- Is this block (a) opaque and (b) a full 1m cube? This determines whether or not to render the shared face of two adjacent blocks and also whether the player can attach torches, redstone wire, etc to this block.
      Overrides:
      isOpaqueCube in class Block
    • renderAsNormalBlock

      public boolean renderAsNormalBlock()
      Description copied from class: Block
      If this block doesn't render as an ordinary block it will return False (examples: signs, buttons, stairs, etc)
      Overrides:
      renderAsNormalBlock in class Block
    • hasLargeCenterHardPointToFacing

      public boolean hasLargeCenterHardPointToFacing(IBlockAccess blockAccess, int i, int j, int k, int iFacing, boolean bIgnoreTransparency)
      Description copied from class: Block
      large attachment points that can support a full block width
      Overrides:
      hasLargeCenterHardPointToFacing in class Block
    • canGroundCoverRestOnBlock

      public boolean canGroundCoverRestOnBlock(World world, int i, int j, int k)
      Overrides:
      canGroundCoverRestOnBlock in class Block
    • groundCoverRestingOnVisualOffset

      public float groundCoverRestingOnVisualOffset(IBlockAccess blockAccess, int i, int j, int k)
      Overrides:
      groundCoverRestingOnVisualOffset in class Block
    • isSnowCoveringTopSurface

      public boolean isSnowCoveringTopSurface(IBlockAccess blockAccess, int i, int j, int k)
      Description copied from class: Block
      Used by blocks like grass and mycellium to determine if they should use a snow side texture. Note that this refers to the top visible surface, not just the top facing, which means that stuff like half-slabs should only return true if they have ground cover actually on the top surface halfway up the block vertically.
      Overrides:
      isSnowCoveringTopSurface in class Block
    • hasContactPointToFullFace

      public boolean hasContactPointToFullFace(IBlockAccess blockAccess, int i, int j, int k, int iFacing)
      Overrides:
      hasContactPointToFullFace in class Block
    • hasContactPointToSlabSideFace

      public boolean hasContactPointToSlabSideFace(IBlockAccess blockAccess, int i, int j, int k, int iFacing, boolean bIsSlabUpsideDown)
      Overrides:
      hasContactPointToSlabSideFace in class Block
    • hasNeighborWithMortarInContact

      public boolean hasNeighborWithMortarInContact(World world, int i, int j, int k)
      Overrides:
      hasNeighborWithMortarInContact in class Block
    • hasStickySnowNeighborInContact

      public boolean hasStickySnowNeighborInContact(World world, int i, int j, int k)
      Overrides:
      hasStickySnowNeighborInContact in class Block
    • createStackedBlock

      protected ItemStack createStackedBlock(int iMetadata)
      Description copied from class: Block
      Returns an item stack containing a single instance of the current block type. 'i' is the block's subtype/damage and is ignored for blocks which do not support subtypes. Blocks which cannot be harvested should return null. // +++START EDIT+++ FCNOTE: This is the function used to create the silk-touch drop // ---END EDIT---
      Overrides:
      createStackedBlock in class Block
    • canMobsSpawnOn

      public boolean canMobsSpawnOn(World world, int i, int j, int k)
      Description copied from class: Block
      This is only a first-pass indicator as to whether ANY mobs can spawn on top of the block, so stuff like leaves where only Jungle Spiders can spawn on them, should still return true.
      Overrides:
      canMobsSpawnOn in class Block
    • mobSpawnOnVerticalOffset

      public float mobSpawnOnVerticalOffset(World world, int i, int j, int k)
      Overrides:
      mobSpawnOnVerticalOffset in class Block
    • hasNeighborWithMortarInContact

      protected boolean hasNeighborWithMortarInContact(World world, int i, int j, int k, boolean bIsUpsideDown)
    • hasStickySnowNeighborInContact

      protected boolean hasStickySnowNeighborInContact(World world, int i, int j, int k, boolean bIsUpsideDown)
    • canBePlacedUpsideDownAtLocation

      public boolean canBePlacedUpsideDownAtLocation(World world, int i, int j, int k)
    • getIsUpsideDown

      public boolean getIsUpsideDown(IBlockAccess blockAccess, int i, int j, int k)
    • getIsUpsideDown

      public boolean getIsUpsideDown(int iMetadata)
    • setIsUpsideDown

      public void setIsUpsideDown(World world, int i, int j, int k, boolean bUpsideDown)
    • setIsUpsideDown

      public int setIsUpsideDown(int iMetadata, boolean bUpsideDown)
    • convertToFullBlock

      public boolean convertToFullBlock(World world, int i, int j, int k)
    • getCombinedBlockID

      public abstract int getCombinedBlockID(int iMetadata)
    • getCombinedMetadata

      public int getCombinedMetadata(int iMetadata)
    • getBlockBoundsFromPoolFromMetadata

      protected AxisAlignedBB getBlockBoundsFromPoolFromMetadata(int iMetadata)
    • shouldSideBeRendered

      @Environment(CLIENT) public boolean shouldSideBeRendered(IBlockAccess blockAccess, int iNeighborI, int iNeighborJ, int iNeighborK, int iSide)
      Overrides:
      shouldSideBeRendered in class Block
    • shouldRenderNeighborHalfSlabSide

      @Environment(CLIENT) public boolean shouldRenderNeighborHalfSlabSide(IBlockAccess blockAccess, int i, int j, int k, int iNeighborSlabSide, boolean bNeighborUpsideDown)
      Overrides:
      shouldRenderNeighborHalfSlabSide in class Block
    • shouldRenderNeighborFullFaceSide

      @Environment(CLIENT) public boolean shouldRenderNeighborFullFaceSide(IBlockAccess blockAccess, int i, int j, int k, int iNeighborSide)
      Overrides:
      shouldRenderNeighborFullFaceSide in class Block