Class FarmlandBlockBase

java.lang.Object
net.minecraft.src.Block
btw.block.blocks.FarmlandBlockBase
Direct Known Subclasses:
FarmlandBlock, LegacyFarmlandBlockBase

public abstract class FarmlandBlockBase extends Block
  • Field Details

    • iconTopWet

      @Environment(CLIENT) protected Icon iconTopWet
    • iconTopDry

      @Environment(CLIENT) protected Icon iconTopDry
  • Constructor Details

    • FarmlandBlockBase

      protected FarmlandBlockBase(int iBlockID)
  • Method Details

    • updateTick

      public void updateTick(World world, int i, int j, int k, Random rand)
      Description copied from class: Block
      Ticks the block if it's been scheduled // +++START EDIT+++ FCNOTE: Called on server only // ---END EDIT---
      Overrides:
      updateTick in class Block
    • getCollisionBoundingBoxFromPool

      public AxisAlignedBB getCollisionBoundingBoxFromPool(World world, int i, int j, int k)
      Overrides:
      getCollisionBoundingBoxFromPool 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
    • onFallenUpon

      public void onFallenUpon(World world, int i, int j, int k, Entity entity, float fFallDist)
      Description copied from class: Block
      Block's chance to react to an entity falling on it.
      Overrides:
      onFallenUpon in class Block
    • getMovementModifier

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

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

      public boolean dropComponentItemsOnBadBreak(World world, int i, int j, int k, int iMetadata, float fChanceOfDrop)
      Description copied from class: Block
      Called by explosions and improper tool use. Should return true if the block processes its own drops through this method, false otherwise Note that the block may no longer be at the specified position when this is called
      Overrides:
      dropComponentItemsOnBadBreak in class Block
    • canBePistonShoveled

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

      public void onVegetationAboveGrazed(World world, int i, int j, int k, EntityAnimal animal)
      Overrides:
      onVegetationAboveGrazed in class Block
    • canDomesticatedCropsGrowOnBlock

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

      public boolean canWildVegetationGrowOnBlock(World world, int i, int j, int k)
      Description copied from class: Block
      Covers stuff like flowers and tall grass
      Overrides:
      canWildVegetationGrowOnBlock in class Block
    • isBlockHydratedForPlantGrowthOn

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

      public void onEntityCollidedWithBlock(World world, int i, int j, int k, Entity entity)
      Description copied from class: Block
      Triggered whenever an entity collides with this block (enters into the block). Args: world, x, y, z, entity
      Overrides:
      onEntityCollidedWithBlock in class Block
    • groundCoverRestingOnVisualOffset

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

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

      public boolean getCanBlightSpreadToBlock(World world, int i, int j, int k, int iBlightLevel)
      Overrides:
      getCanBlightSpreadToBlock in class Block
    • isBreakableBarricade

      public boolean isBreakableBarricade(World world, int i, int j, int k, boolean advancedBreaker)
      Overrides:
      isBreakableBarricade in class Block
    • isHydrated

      protected boolean isHydrated(World world, int i, int j, int k)
    • isHydrated

      protected abstract boolean isHydrated(int iMetadata)
    • setFullyHydrated

      protected void setFullyHydrated(World world, int i, int j, int k)
    • setFullyHydrated

      protected abstract int setFullyHydrated(int iMetadata)
    • dryIncrementally

      protected abstract void dryIncrementally(World world, int i, int j, int k)
    • isFertilized

      protected abstract boolean isFertilized(IBlockAccess blockAccess, int i, int j, int k)
    • setFertilized

      protected void setFertilized(World world, int i, int j, int k)
    • getHorizontalHydrationRange

      protected int getHorizontalHydrationRange(World world, int i, int j, int k)
    • hasIrrigatingBlocks

      protected boolean hasIrrigatingBlocks(World world, int i, int j, int k)
    • doesBlockAbovePreventSoilReversion

      protected boolean doesBlockAbovePreventSoilReversion(World world, int i, int j, int k)
    • checkForSoilReversion

      protected void checkForSoilReversion(World world, int i, int j, int k)
    • 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
    • getIcon

      @Environment(CLIENT) public Icon getIcon(int iSide, int iMetadata)
      Description copied from class: Block
      From the specified side and block metadata retrieves the blocks texture. Args: side, metadata
      Overrides:
      getIcon in class Block
    • idPicked

      @Environment(CLIENT) public int idPicked(World world, int i, int j, int k)
      Description copied from class: Block
      only called by clickMiddleMouseButton , and passed to inventory.setCurrentItem (along with isCreative) // +++START EDIT+++ FCNOTE: Client only // ---END EDIT---
      Overrides:
      idPicked in class Block
    • shouldSideBeRendered

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