Interface IBlockGrowable

All Known Implementing Classes:
BlockCarrot, BlockCocoa, BlockCrops, BlockDoublePlant, BlockGrass, BlockMushroom, BlockPotato, BlockSapling, BlockStem, BlockTallGrass

public interface IBlockGrowable
Represents a growable block.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Called to check if the block will effectively grow.
    void
    grow(GlowPlayer player, GlowBlock block)
    Called to grow a growable block.
    boolean
    Called to check if a block can be fertilized.
  • Method Details

    • isFertilizable

      boolean isFertilizable(GlowBlock block)
      Called to check if a block can be fertilized.
      Parameters:
      block - the targeted block to fertilize
      Returns:
      True if the block can be fertilized.
    • canGrowWithChance

      boolean canGrowWithChance(GlowBlock block)
      Called to check if the block will effectively grow.
      Parameters:
      block - the targeted block to grow
      Returns:
      True if the block will grow.
    • grow

      void grow(GlowPlayer player, GlowBlock block)
      Called to grow a growable block.
      Parameters:
      player - the player who triggered the growth, this can be null if the growth is natural or by plugin source
      block - the targeted block to grow