Class MobSpawnerBlock

All Implemented Interfaces:
BlockEntityProvider

public class MobSpawnerBlock extends BlockWithEntity
Mappings:
Namespace Name
official axr
intermediary net/minecraft/class_159
named net/minecraft/block/MobSpawnerBlock
  • Constructor Details

    • MobSpawnerBlock

      protected MobSpawnerBlock()
  • Method Details

    • createBlockEntity

      public BlockEntity createBlockEntity(World world, int id)
      Mappings:
      Namespace Name Mixin selector
      official a Lavs;a(Laqu;I)Lbcm;
      intermediary method_309 Lnet/minecraft/class_1451;method_309(Lnet/minecraft/class_1150;I)Lnet/minecraft/class_226;
      named createBlockEntity Lnet/minecraft/block/BlockEntityProvider;createBlockEntity(Lnet/minecraft/world/World;I)Lnet/minecraft/block/entity/BlockEntity;
    • getDropItem

      public Item getDropItem(BlockState blockState, Random random, int state)
      Returns the item that must be dropped when the block is broken
      Overrides:
      getDropItem in class Block
      Parameters:
      blockState - The block's BlockState
      random - Random object
      state - State
      Returns:
      The Item that drops after the block breaks
      Mappings:
      Namespace Name Mixin selector
      official a Latr;a(Lbec;Ljava/util/Random;I)Lalq;
      intermediary method_398 Lnet/minecraft/class_197;method_398(Lnet/minecraft/class_2232;Ljava/util/Random;I)Lnet/minecraft/class_1069;
      named getDropItem Lnet/minecraft/block/Block;getDropItem(Lnet/minecraft/block/BlockState;Ljava/util/Random;I)Lnet/minecraft/item/Item;
    • getDropCount

      public int getDropCount(Random rand)
      Returns the amount of items the block should drop on breaking without bonus rolls.
      Overrides:
      getDropCount in class Block
      Parameters:
      rand - Random object
      Returns:
      Amount of items to be dropped
      Mappings:
      Namespace Name Mixin selector
      official a Latr;a(Ljava/util/Random;)I
      intermediary method_403 Lnet/minecraft/class_197;method_403(Ljava/util/Random;)I
      named getDropCount Lnet/minecraft/block/Block;getDropCount(Ljava/util/Random;)I
    • randomDropAsItem

      public void randomDropAsItem(World world, BlockPos pos, BlockState state, float chance, int id)
      Called when the block must be dropped as an item by dropAsItem, but luck is taken into consideration here.
      Overrides:
      randomDropAsItem in class Block
      Parameters:
      world - The world that the block is placed in
      pos - The block's position
      state - The block's BlockState
      chance - The chance (luck factor)
      id - Id
      Mappings:
      Namespace Name Mixin selector
      official a Latr;a(Laqu;Ldt;Lbec;FI)V
      intermediary method_410 Lnet/minecraft/class_197;method_410(Lnet/minecraft/class_1150;Lnet/minecraft/class_2552;Lnet/minecraft/class_2232;FI)V
      named randomDropAsItem Lnet/minecraft/block/Block;randomDropAsItem(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;FI)V
    • hasTransperancy

      public boolean hasTransperancy()
      Overrides:
      hasTransperancy in class Block
      Mappings:
      Namespace Name Mixin selector
      official c Latr;c()Z
      intermediary method_449 Lnet/minecraft/class_197;method_449()Z
      named hasTransperancy Lnet/minecraft/block/Block;hasTransperancy()Z
    • getBlockType

      public int getBlockType()
      Overrides:
      getBlockType in class BlockWithEntity
      Mappings:
      Namespace Name Mixin selector
      official b Latr;b()I
      intermediary method_429 Lnet/minecraft/class_197;method_429()I
      named getBlockType Lnet/minecraft/block/Block;getBlockType()I
    • getRenderLayerType

      @Environment(CLIENT) public BlockRenderLayer getRenderLayerType()
      Returns the appropriate RenderLayer for a block. Only called on the client.
      Overrides:
      getRenderLayerType in class Block
      Returns:
      The block's RenderLayer
      Mappings:
      Namespace Name Mixin selector
      official k Latr;k()Laql;
      intermediary method_8687 Lnet/minecraft/class_197;method_8687()Lnet/minecraft/class_2165;
      named getRenderLayerType Lnet/minecraft/block/Block;getRenderLayerType()Lnet/minecraft/client/render/BlockRenderLayer;
    • getPickItem

      @Environment(CLIENT) public Item getPickItem(World world, BlockPos pos)
      Called when a player presses the pick block key while facing the block. It returns the item that must be placed into the player's inventory.
      Overrides:
      getPickItem in class Block
      Returns:
      The Item that must be placed into the player's inventory
      Mappings:
      Namespace Name Mixin selector
      official b Latr;b(Laqu;Ldt;)Lalq;
      intermediary method_8667 Lnet/minecraft/class_197;method_8667(Lnet/minecraft/class_1150;Lnet/minecraft/class_2552;)Lnet/minecraft/class_1069;
      named getPickItem Lnet/minecraft/block/Block;getPickItem(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;)Lnet/minecraft/item/Item;