Class BannerBlock

All Implemented Interfaces:
BlockEntityProvider
Direct Known Subclasses:
BannerBlock.StandingBannerBlock, BannerBlock.WallBannerBlock

public class BannerBlock
extends BlockWithEntity
Mappings:
Namespace Name
official afa
intermediary net/minecraft/class_148
named net/minecraft/block/BannerBlock
  • Field Details

    • FACING

      public static final DirectionProperty FACING
      Mappings:
      Namespace Name Mixin selector
      official a Lafa;a:Laml;
      intermediary field_540 Lnet/minecraft/class_148;field_540:Lnet/minecraft/class_389;
      named FACING Lnet/minecraft/block/BannerBlock;FACING:Lnet/minecraft/state/property/DirectionProperty;
    • ROTATION

      public static final IntProperty ROTATION
      Mappings:
      Namespace Name Mixin selector
      official b Lafa;b:Lamn;
      intermediary field_541 Lnet/minecraft/class_148;field_541:Lnet/minecraft/class_391;
      named ROTATION Lnet/minecraft/block/BannerBlock;ROTATION:Lnet/minecraft/state/property/IntProperty;
  • Constructor Details

    • BannerBlock

      protected BannerBlock()
  • 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_716 Lnet/minecraft/class_160;method_716()Ljava/lang/String;
      named getTranslatedName Lnet/minecraft/block/Block;getTranslatedName()Ljava/lang/String;
    • getCollisionBox

      public Box getCollisionBox​(World world, BlockPos pos, BlockState state)
      Returns a box by adding the block's current location and the block's corresponding value in its Bounding Box
      Overrides:
      getCollisionBox in class Block
      Parameters:
      world - The world that the block has been placed
      pos - The block's position
      state - The block's BlockState
      Returns:
      The Collision box
      Mappings:
      Namespace Name Mixin selector
      official a Lafh;a(Ladm;Lcj;Lalz;)Laug;
      intermediary method_645 Lnet/minecraft/class_160;method_645(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;)Lnet/minecraft/class_646;
      named getCollisionBox Lnet/minecraft/block/Block;getCollisionBox(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)Lnet/minecraft/util/math/Box;
    • getSelectionBox

      @Environment(CLIENT) public Box getSelectionBox​(World world, BlockPos pos)
      Overrides:
      getSelectionBox in class Block
      Mappings:
      Namespace Name Mixin selector
      official b Lafh;b(Ladm;Lcj;)Laug;
      intermediary method_686 Lnet/minecraft/class_160;method_686(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;)Lnet/minecraft/class_646;
      named getSelectionBox Lnet/minecraft/block/Block;getSelectionBox(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;)Lnet/minecraft/util/math/Box;
    • renderAsNormalBlock

      public boolean renderAsNormalBlock()
      Returns whether the block can be rendered as a normal block
      Overrides:
      renderAsNormalBlock in class Block
      Returns:
      Whether the block can be rendered as a normal block
      Mappings:
      Namespace Name Mixin selector
      official d Lafh;d()Z
      intermediary method_709 Lnet/minecraft/class_160;method_709()Z
      named renderAsNormalBlock Lnet/minecraft/block/Block;renderAsNormalBlock()Z
    • blocksMovement

      public boolean blocksMovement​(WorldView view, BlockPos pos)
      Overrides:
      blocksMovement in class Block
      Mappings:
      Namespace Name Mixin selector
      official b Lafh;b(Ladq;Lcj;)Z
      intermediary method_692 Lnet/minecraft/class_160;method_692(Lnet/minecraft/class_104;Lnet/minecraft/class_1372;)Z
      named blocksMovement Lnet/minecraft/block/Block;blocksMovement(Lnet/minecraft/world/WorldView;Lnet/minecraft/util/math/BlockPos;)Z
    • hasTransperancy

      public boolean hasTransperancy()
      Overrides:
      hasTransperancy in class Block
      Mappings:
      Namespace Name Mixin selector
      official c Lafh;c()Z
      intermediary method_699 Lnet/minecraft/class_160;method_699()Z
      named hasTransperancy Lnet/minecraft/block/Block;hasTransperancy()Z
    • canMobSpawnInside

      public boolean canMobSpawnInside()
      Returns whether mobs can spawn inside the block. Used for Air.
      Overrides:
      canMobSpawnInside in class Block
      Returns:
      Whether mobs can spawn inside the block
      Mappings:
      Namespace Name Mixin selector
      official g Lafh;g()Z
      intermediary method_718 Lnet/minecraft/class_160;method_718()Z
      named canMobSpawnInside Lnet/minecraft/block/Block;canMobSpawnInside()Z
    • createBlockEntity

      public BlockEntity createBlockEntity​(World world, int id)
      Mappings:
      Namespace Name Mixin selector
      official a Lagq;a(Ladm;I)Lakw;
      intermediary method_841 Lnet/minecraft/class_205;method_841(Lnet/minecraft/class_99;I)Lnet/minecraft/class_348;
      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 Lafh;a(Lalz;Ljava/util/Random;I)Lzw;
      intermediary method_674 Lnet/minecraft/class_160;method_674(Lnet/minecraft/class_376;Ljava/util/Random;I)Lnet/minecraft/class_2054;
      named getDropItem Lnet/minecraft/block/Block;getDropItem(Lnet/minecraft/block/BlockState;Ljava/util/Random;I)Lnet/minecraft/item/Item;
    • 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 c Lafh;c(Ladm;Lcj;)Lzw;
      intermediary method_702 Lnet/minecraft/class_160;method_702(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;)Lnet/minecraft/class_2054;
      named getPickItem Lnet/minecraft/block/Block;getPickItem(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;)Lnet/minecraft/item/Item;
    • 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 Lafh;a(Ladm;Lcj;Lalz;FI)V
      intermediary method_646 Lnet/minecraft/class_160;method_646(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;FI)V
      named randomDropAsItem Lnet/minecraft/block/Block;randomDropAsItem(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;FI)V
    • canBePlacedAtPos

      public boolean canBePlacedAtPos​(World world, BlockPos pos)
      Returns whether the current block can be placed at a certain BlockPos
      Overrides:
      canBePlacedAtPos in class Block
      Returns:
      Whether the current block can be placed at a BlockPos
      Mappings:
      Namespace Name Mixin selector
      official d Lafh;d(Ladm;Lcj;)Z
      intermediary method_711 Lnet/minecraft/class_160;method_711(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;)Z
      named canBePlacedAtPos Lnet/minecraft/block/Block;canBePlacedAtPos(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;)Z
    • harvest

      public void harvest​(World world, PlayerEntity player, BlockPos pos, BlockState state, BlockEntity be)
      Runs every time a player begins to break the block.
      Overrides:
      harvest in class Block
      Parameters:
      world - The world that the block is placed in
      player - The player who is mining the block
      pos - The block's position
      state - The block's BlockState
      be - The block entity in the block
      Mappings:
      Namespace Name Mixin selector
      official a Lafh;a(Ladm;Lwn;Lcj;Lalz;Lakw;)V
      intermediary method_664 Lnet/minecraft/class_160;method_664(Lnet/minecraft/class_99;Lnet/minecraft/class_1963;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;Lnet/minecraft/class_348;)V
      named harvest Lnet/minecraft/block/Block;harvest(Lnet/minecraft/world/World;Lnet/minecraft/entity/player/PlayerEntity;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Lnet/minecraft/block/entity/BlockEntity;)V