Class SaplingBlock

All Implemented Interfaces:
Growable

public class SaplingBlock extends PlantBlock implements Growable
Mappings:
Namespace Name
official ajj
intermediary net/minecraft/class_183
named net/minecraft/block/SaplingBlock
  • Field Details

    • TYPE

      public static final EnumProperty<PlanksBlock.WoodType> TYPE
      Mappings:
      Namespace Name Mixin selector
      official a Lajj;a:Lamm;
      intermediary field_9660 Lnet/minecraft/class_183;field_9660:Lnet/minecraft/class_2245;
      named TYPE Lnet/minecraft/block/SaplingBlock;TYPE:Lnet/minecraft/state/property/EnumProperty;
    • STAGE

      public static final IntProperty STAGE
      Mappings:
      Namespace Name Mixin selector
      official b Lajj;b:Lamn;
      intermediary field_9661 Lnet/minecraft/class_183;field_9661:Lnet/minecraft/class_2246;
      named STAGE Lnet/minecraft/block/SaplingBlock;STAGE:Lnet/minecraft/state/property/IntProperty;
  • Constructor Details

    • SaplingBlock

      protected SaplingBlock()
  • Method Details

    • getTranslatedName

      public String getTranslatedName()
      Translates and returns the translation key
      Overrides:
      getTranslatedName in class Block
      Returns:
      Translated name
      Mappings:
      Namespace Name Mixin selector
      official f Lafh;f()Ljava/lang/String;
      intermediary method_480 Lnet/minecraft/class_197;method_480()Ljava/lang/String;
      named getTranslatedName Lnet/minecraft/block/Block;getTranslatedName()Ljava/lang/String;
    • scheduledTick

      public void scheduledTick(World world, BlockPos pos, BlockState state, Random rand)
      Runs when the block is updated as per a schedule
      Overrides:
      scheduledTick in class PlantBlock
      Parameters:
      world - The world that the block is placed in
      pos - The block's position
      state - The block's BlockState
      rand - Random object
      Mappings:
      Namespace Name Mixin selector
      official b Lafh;b(Ladm;Lcj;Lalz;Ljava/util/Random;)V
      intermediary method_8661 Lnet/minecraft/class_197;method_8661(Lnet/minecraft/class_1150;Lnet/minecraft/class_2552;Lnet/minecraft/class_2232;Ljava/util/Random;)V
      named scheduledTick Lnet/minecraft/block/Block;scheduledTick(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Ljava/util/Random;)V
    • method_8897

      public void method_8897(World world, BlockPos blockPos, BlockState blockState, Random random)
      Mappings:
      Namespace Name Mixin selector
      official d Lajj;d(Ladm;Lcj;Lalz;Ljava/util/Random;)V
      intermediary method_8897 Lnet/minecraft/class_183;method_8897(Lnet/minecraft/class_1150;Lnet/minecraft/class_2552;Lnet/minecraft/class_2232;Ljava/util/Random;)V
      named method_8897 Lnet/minecraft/block/SaplingBlock;method_8897(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Ljava/util/Random;)V
    • method_8898

      public void method_8898(World world, BlockPos blockPos, BlockState blockState, Random random)
      Mappings:
      Namespace Name Mixin selector
      official e Lajj;e(Ladm;Lcj;Lalz;Ljava/util/Random;)V
      intermediary method_8898 Lnet/minecraft/class_183;method_8898(Lnet/minecraft/class_1150;Lnet/minecraft/class_2552;Lnet/minecraft/class_2232;Ljava/util/Random;)V
      named method_8898 Lnet/minecraft/block/SaplingBlock;method_8898(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Ljava/util/Random;)V
    • method_8895

      private boolean method_8895(World world, BlockPos blockPos, int int2, int int3, PlanksBlock.WoodType woodType)
      Mappings:
      Namespace Name Mixin selector
      official a Lajj;a(Ladm;Lcj;IILaio$a;)Z
      intermediary method_8895 Lnet/minecraft/class_183;method_8895(Lnet/minecraft/class_1150;Lnet/minecraft/class_2552;IILnet/minecraft/class_213$class_2202;)Z
      named method_8895 Lnet/minecraft/block/SaplingBlock;method_8895(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;IILnet/minecraft/block/PlanksBlock$WoodType;)Z
    • method_8896

      public boolean method_8896(World world, BlockPos blockPos, PlanksBlock.WoodType woodType)
      Mappings:
      Namespace Name Mixin selector
      official a Lajj;a(Ladm;Lcj;Laio$a;)Z
      intermediary method_8896 Lnet/minecraft/class_183;method_8896(Lnet/minecraft/class_1150;Lnet/minecraft/class_2552;Lnet/minecraft/class_213$class_2202;)Z
      named method_8896 Lnet/minecraft/block/SaplingBlock;method_8896(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/PlanksBlock$WoodType;)Z
    • getMeta

      public int getMeta(BlockState state)
      Returns the metadata value for a certain BlockState
      Overrides:
      getMeta in class Block
      Parameters:
      state - The BlockState
      Returns:
      Metadata value
      Mappings:
      Namespace Name Mixin selector
      official a Lafh;a(Lalz;)I
      intermediary method_8655 Lnet/minecraft/class_197;method_8655(Lnet/minecraft/class_2232;)I
      named getMeta Lnet/minecraft/block/Block;getMeta(Lnet/minecraft/block/BlockState;)I
    • appendItemStacks

      @Environment(CLIENT) public void appendItemStacks(Item item, ItemGroup group, List<ItemStack> stacks)
      Appends ItemStacks to an itemgroup. Only called on the client.
      Overrides:
      appendItemStacks in class Block
      Parameters:
      item - The Item that must be added
      group - The ItemGroup that the item must be added to
      stacks - The list of currently added ItemStacks to the ItemGroup
      Mappings:
      Namespace Name Mixin selector
      official a Lafh;a(Lzw;Lyz;Ljava/util/List;)V
      intermediary method_399 Lnet/minecraft/class_197;method_399(Lnet/minecraft/class_1069;Lnet/minecraft/class_1041;Ljava/util/List;)V
      named appendItemStacks Lnet/minecraft/block/Block;appendItemStacks(Lnet/minecraft/item/Item;Lnet/minecraft/item/itemgroup/ItemGroup;Ljava/util/List;)V
    • canGrow

      public boolean canGrow(World world, BlockPos pos, BlockState state, boolean bl)
      Specified by:
      canGrow in interface Growable
      Mappings:
      Namespace Name Mixin selector
      official a Lafj;a(Ladm;Lcj;Lalz;Z)Z
      intermediary method_6460 Lnet/minecraft/class_1753;method_6460(Lnet/minecraft/class_1150;Lnet/minecraft/class_2552;Lnet/minecraft/class_2232;Z)Z
      named canGrow Lnet/minecraft/block/Growable;canGrow(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Z)Z
    • canBeFertilized

      public boolean canBeFertilized(World world, Random random, BlockPos pos, BlockState state)
      Specified by:
      canBeFertilized in interface Growable
      Mappings:
      Namespace Name Mixin selector
      official a Lafj;a(Ladm;Ljava/util/Random;Lcj;Lalz;)Z
      intermediary method_6461 Lnet/minecraft/class_1753;method_6461(Lnet/minecraft/class_1150;Ljava/util/Random;Lnet/minecraft/class_2552;Lnet/minecraft/class_2232;)Z
      named canBeFertilized Lnet/minecraft/block/Growable;canBeFertilized(Lnet/minecraft/world/World;Ljava/util/Random;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)Z
    • grow

      public void grow(World world, Random random, BlockPos pos, BlockState state)
      Specified by:
      grow in interface Growable
      Mappings:
      Namespace Name Mixin selector
      official b Lafj;b(Ladm;Ljava/util/Random;Lcj;Lalz;)V
      intermediary method_6462 Lnet/minecraft/class_1753;method_6462(Lnet/minecraft/class_1150;Ljava/util/Random;Lnet/minecraft/class_2552;Lnet/minecraft/class_2232;)V
      named grow Lnet/minecraft/block/Growable;grow(Lnet/minecraft/world/World;Ljava/util/Random;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)V
    • stateFromData

      public BlockState stateFromData(int data)
      Returns a blockstate of the current block from it's id
      Overrides:
      stateFromData in class Block
      Parameters:
      data - The Blockstate's associated data value
      Returns:
      The Default state
      Mappings:
      Namespace Name Mixin selector
      official a Lafh;a(I)Lalz;
      intermediary method_8635 Lnet/minecraft/class_197;method_8635(I)Lnet/minecraft/class_2232;
      named stateFromData Lnet/minecraft/block/Block;stateFromData(I)Lnet/minecraft/block/BlockState;
    • getData

      public int getData(BlockState state)
      Returns the data value for a blockstate Throws an IllegalArmumentException as this method does not work
      Overrides:
      getData in class Block
      Parameters:
      state - The Blockstate
      Returns:
      Zero
      Mappings:
      Namespace Name Mixin selector
      official c Lafh;c(Lalz;)I
      intermediary method_8671 Lnet/minecraft/class_197;method_8671(Lnet/minecraft/class_2232;)I
      named getData Lnet/minecraft/block/Block;getData(Lnet/minecraft/block/BlockState;)I
    • appendProperties

      protected StateManager appendProperties()
      Returns a new state manager with a property array.
      Overrides:
      appendProperties in class Block
      Returns:
      New state manager
      Mappings:
      Namespace Name Mixin selector
      official e Lafh;e()Lama;
      intermediary method_8676 Lnet/minecraft/class_197;method_8676()Lnet/minecraft/class_2233;
      named appendProperties Lnet/minecraft/block/Block;appendProperties()Lnet/minecraft/state/StateManager;