Class RespawnAnchorBlock

All Implemented Interfaces:
ItemConvertible, ToggleableFeature

public class RespawnAnchorBlock extends Block
Mappings:
Namespace Name
named net/minecraft/block/RespawnAnchorBlock
intermediary net/minecraft/class_4969
official dli
  • Field Details

    • CODEC

      public static final com.mojang.serialization.MapCodec<RespawnAnchorBlock> CODEC
      Mappings:
      Namespace Name Mixin selector
      named CODEC Lnet/minecraft/block/RespawnAnchorBlock;CODEC:Lcom/mojang/serialization/MapCodec;
      intermediary field_46427 Lnet/minecraft/class_4969;field_46427:Lcom/mojang/serialization/MapCodec;
      official a Ldli;a:Lcom/mojang/serialization/MapCodec;
    • NO_CHARGES

      public static final int NO_CHARGES
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named NO_CHARGES Lnet/minecraft/block/RespawnAnchorBlock;NO_CHARGES:I
      intermediary field_31231 Lnet/minecraft/class_4969;field_31231:I
      official b Ldli;b:I
    • MAX_CHARGES

      public static final int MAX_CHARGES
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named MAX_CHARGES Lnet/minecraft/block/RespawnAnchorBlock;MAX_CHARGES:I
      intermediary field_31232 Lnet/minecraft/class_4969;field_31232:I
      official c Ldli;c:I
    • CHARGES

      public static final IntProperty CHARGES
      Mappings:
      Namespace Name Mixin selector
      named CHARGES Lnet/minecraft/block/RespawnAnchorBlock;CHARGES:Lnet/minecraft/state/property/IntProperty;
      intermediary field_23153 Lnet/minecraft/class_4969;field_23153:Lnet/minecraft/class_2758;
      official d Ldli;d:Ldtd;
    • VALID_HORIZONTAL_SPAWN_OFFSETS

      private static final ImmutableList<Vec3i> VALID_HORIZONTAL_SPAWN_OFFSETS
      Mappings:
      Namespace Name Mixin selector
      named VALID_HORIZONTAL_SPAWN_OFFSETS Lnet/minecraft/block/RespawnAnchorBlock;VALID_HORIZONTAL_SPAWN_OFFSETS:Lcom/google/common/collect/ImmutableList;
      intermediary field_26442 Lnet/minecraft/class_4969;field_26442:Lcom/google/common/collect/ImmutableList;
      official e Ldli;e:Lcom/google/common/collect/ImmutableList;
    • VALID_SPAWN_OFFSETS

      private static final ImmutableList<Vec3i> VALID_SPAWN_OFFSETS
      Mappings:
      Namespace Name Mixin selector
      named VALID_SPAWN_OFFSETS Lnet/minecraft/block/RespawnAnchorBlock;VALID_SPAWN_OFFSETS:Lcom/google/common/collect/ImmutableList;
      intermediary field_26443 Lnet/minecraft/class_4969;field_26443:Lcom/google/common/collect/ImmutableList;
      official f Ldli;f:Lcom/google/common/collect/ImmutableList;
  • Constructor Details

    • RespawnAnchorBlock

      public RespawnAnchorBlock(AbstractBlock.Settings settings)
      Mappings:
      Namespace Name Mixin selector
      named <init> Lnet/minecraft/block/AbstractBlock;<init>(Lnet/minecraft/block/AbstractBlock$Settings;)V
      intermediary <init> Lnet/minecraft/class_4970;<init>(Lnet/minecraft/class_4970$class_2251;)V
      official <init> Ldsc;<init>(Ldsc$d;)V
  • Method Details

    • getCodec

      public com.mojang.serialization.MapCodec<RespawnAnchorBlock> getCodec()
      Overrides:
      getCodec in class Block
      Mappings:
      Namespace Name Mixin selector
      named getCodec Lnet/minecraft/block/AbstractBlock;getCodec()Lcom/mojang/serialization/MapCodec;
      intermediary method_53969 Lnet/minecraft/class_4970;method_53969()Lcom/mojang/serialization/MapCodec;
      official a Ldsc;a()Lcom/mojang/serialization/MapCodec;
    • onUseWithItem

      protected ItemActionResult onUseWithItem(ItemStack stack, BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit)
      Overrides:
      onUseWithItem in class AbstractBlock
      Mappings:
      Namespace Name Mixin selector
      named onUseWithItem Lnet/minecraft/block/AbstractBlock;onUseWithItem(Lnet/minecraft/item/ItemStack;Lnet/minecraft/block/BlockState;Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/entity/player/PlayerEntity;Lnet/minecraft/util/Hand;Lnet/minecraft/util/hit/BlockHitResult;)Lnet/minecraft/util/ItemActionResult;
      intermediary method_55765 Lnet/minecraft/class_4970;method_55765(Lnet/minecraft/class_1799;Lnet/minecraft/class_2680;Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;Lnet/minecraft/class_1657;Lnet/minecraft/class_1268;Lnet/minecraft/class_3965;)Lnet/minecraft/class_9062;
      official a Ldsc;a(Lcuq;Ldsd;Ldbz;Liz;Lcmy;Lbqu;Levo;)Lbqx;
    • onUse

      protected ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, BlockHitResult hit)
      Overrides:
      onUse in class AbstractBlock
      Mappings:
      Namespace Name Mixin selector
      named onUse Lnet/minecraft/block/AbstractBlock;onUse(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/entity/player/PlayerEntity;Lnet/minecraft/util/hit/BlockHitResult;)Lnet/minecraft/util/ActionResult;
      intermediary method_55766 Lnet/minecraft/class_4970;method_55766(Lnet/minecraft/class_2680;Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;Lnet/minecraft/class_1657;Lnet/minecraft/class_3965;)Lnet/minecraft/class_1269;
      official a Ldsc;a(Ldsd;Ldbz;Liz;Lcmy;Levo;)Lbqv;
    • isChargeItem

      private static boolean isChargeItem(ItemStack stack)
      Mappings:
      Namespace Name Mixin selector
      named isChargeItem Lnet/minecraft/block/RespawnAnchorBlock;isChargeItem(Lnet/minecraft/item/ItemStack;)Z
      intermediary method_29289 Lnet/minecraft/class_4969;method_29289(Lnet/minecraft/class_1799;)Z
      official a Ldli;a(Lcuq;)Z
    • canCharge

      private static boolean canCharge(BlockState state)
      Mappings:
      Namespace Name Mixin selector
      named canCharge Lnet/minecraft/block/RespawnAnchorBlock;canCharge(Lnet/minecraft/block/BlockState;)Z
      intermediary method_29290 Lnet/minecraft/class_4969;method_29290(Lnet/minecraft/class_2680;)Z
      official m Ldli;m(Ldsd;)Z
    • hasStillWater

      private static boolean hasStillWater(BlockPos pos, World world)
      Mappings:
      Namespace Name Mixin selector
      named hasStillWater Lnet/minecraft/block/RespawnAnchorBlock;hasStillWater(Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/world/World;)Z
      intermediary method_29560 Lnet/minecraft/class_4969;method_29560(Lnet/minecraft/class_2338;Lnet/minecraft/class_1937;)Z
      official a Ldli;a(Liz;Ldbz;)Z
    • explode

      private void explode(BlockState state, World world, BlockPos explodedPos)
      Mappings:
      Namespace Name Mixin selector
      named explode Lnet/minecraft/block/RespawnAnchorBlock;explode(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;)V
      intermediary method_29561 Lnet/minecraft/class_4969;method_29561(Lnet/minecraft/class_2680;Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;)V
      official d Ldli;d(Ldsd;Ldbz;Liz;)V
    • isNether

      public static boolean isNether(World world)
      Mappings:
      Namespace Name Mixin selector
      named isNether Lnet/minecraft/block/RespawnAnchorBlock;isNether(Lnet/minecraft/world/World;)Z
      intermediary method_27353 Lnet/minecraft/class_4969;method_27353(Lnet/minecraft/class_1937;)Z
      official a Ldli;a(Ldbz;)Z
    • charge

      public static void charge(@Nullable @Nullable Entity charger, World world, BlockPos pos, BlockState state)
      Mappings:
      Namespace Name Mixin selector
      named charge Lnet/minecraft/block/RespawnAnchorBlock;charge(Lnet/minecraft/entity/Entity;Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)V
      intermediary method_26382 Lnet/minecraft/class_4969;method_26382(Lnet/minecraft/class_1297;Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;)V
      official a Ldli;a(Lbsv;Ldbz;Liz;Ldsd;)V
    • randomDisplayTick

      public void randomDisplayTick(BlockState state, World world, BlockPos pos, Random random)
      Called randomly on the client. Blocks may override this to spawn particles. Unlike AbstractBlock.randomTick(net.minecraft.block.BlockState, net.minecraft.server.world.ServerWorld, net.minecraft.util.math.BlockPos, net.minecraft.util.math.random.Random) this is not affected by a game rule.
      Overrides:
      randomDisplayTick in class Block
      Mappings:
      Namespace Name Mixin selector
      named randomDisplayTick Lnet/minecraft/block/Block;randomDisplayTick(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/util/math/random/Random;)V
      intermediary method_9496 Lnet/minecraft/class_2248;method_9496(Lnet/minecraft/class_2680;Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;Lnet/minecraft/class_5819;)V
      official a Ldfa;a(Ldsd;Ldbz;Liz;Lazh;)V
    • appendProperties

      protected void appendProperties(StateManager.Builder<Block,BlockState> builder)
      Appends block state properties to this block. To use this, override and call StateManager.Builder.add(net.minecraft.state.property.Property<?>[]) inside the method. See Properties for the list of pre-defined properties.
      Overrides:
      appendProperties in class Block
      Mappings:
      Namespace Name Mixin selector
      named appendProperties Lnet/minecraft/block/Block;appendProperties(Lnet/minecraft/state/StateManager$Builder;)V
      intermediary method_9515 Lnet/minecraft/class_2248;method_9515(Lnet/minecraft/class_2689$class_2690;)V
      official a Ldfa;a(Ldse$a;)V
    • hasComparatorOutput

      protected boolean hasComparatorOutput(BlockState state)
      Returns whether the block can have a comparator output.

      This does not check the current comparator output of the block. Use getComparatorOutput(net.minecraft.block.BlockState, net.minecraft.world.World, net.minecraft.util.math.BlockPos) in that case.

      Overrides:
      hasComparatorOutput in class AbstractBlock
      Returns:
      whether the block can have a comparator output
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named hasComparatorOutput Lnet/minecraft/block/AbstractBlock;hasComparatorOutput(Lnet/minecraft/block/BlockState;)Z
      intermediary method_9498 Lnet/minecraft/class_4970;method_9498(Lnet/minecraft/class_2680;)Z
      official c_ Ldsc;c_(Ldsd;)Z
    • getLightLevel

      public static int getLightLevel(BlockState state, int maxLevel)
      Mappings:
      Namespace Name Mixin selector
      named getLightLevel Lnet/minecraft/block/RespawnAnchorBlock;getLightLevel(Lnet/minecraft/block/BlockState;I)I
      intermediary method_26157 Lnet/minecraft/class_4969;method_26157(Lnet/minecraft/class_2680;I)I
      official a Ldli;a(Ldsd;I)I
    • getComparatorOutput

      protected int getComparatorOutput(BlockState state, World world, BlockPos pos)
      Returns the comparator output of the block, from 0 to 15.

      When overriding this, hasComparatorOutput(net.minecraft.block.BlockState) must also be overridden.

      Overrides:
      getComparatorOutput in class AbstractBlock
      Returns:
      the comparator output of the block, from 0 to 15
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named getComparatorOutput Lnet/minecraft/block/AbstractBlock;getComparatorOutput(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;)I
      intermediary method_9572 Lnet/minecraft/class_4970;method_9572(Lnet/minecraft/class_2680;Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;)I
      official a Ldsc;a(Ldsd;Ldbz;Liz;)I
    • findRespawnPosition

      public static Optional<Vec3d> findRespawnPosition(EntityType<?> entity, CollisionView world, BlockPos pos)
      Mappings:
      Namespace Name Mixin selector
      named findRespawnPosition Lnet/minecraft/block/RespawnAnchorBlock;findRespawnPosition(Lnet/minecraft/entity/EntityType;Lnet/minecraft/world/CollisionView;Lnet/minecraft/util/math/BlockPos;)Ljava/util/Optional;
      intermediary method_26156 Lnet/minecraft/class_4969;method_26156(Lnet/minecraft/class_1299;Lnet/minecraft/class_1941;Lnet/minecraft/class_2338;)Ljava/util/Optional;
      official a Ldli;a(Lbtb;Ldbj;Liz;)Ljava/util/Optional;
    • findRespawnPosition

      private static Optional<Vec3d> findRespawnPosition(EntityType<?> entity, CollisionView world, BlockPos pos, boolean ignoreInvalidPos)
      Mappings:
      Namespace Name Mixin selector
      named findRespawnPosition Lnet/minecraft/block/RespawnAnchorBlock;findRespawnPosition(Lnet/minecraft/entity/EntityType;Lnet/minecraft/world/CollisionView;Lnet/minecraft/util/math/BlockPos;Z)Ljava/util/Optional;
      intermediary method_30842 Lnet/minecraft/class_4969;method_30842(Lnet/minecraft/class_1299;Lnet/minecraft/class_1941;Lnet/minecraft/class_2338;Z)Ljava/util/Optional;
      official a Ldli;a(Lbtb;Ldbj;Liz;Z)Ljava/util/Optional;
    • canPathfindThrough

      protected boolean canPathfindThrough(BlockState state, NavigationType type)
      Returns if an entity using navigation type type can navigate through this block.
      Overrides:
      canPathfindThrough in class AbstractBlock
      Returns:
      if an entity using navigation type type can navigate through this block
      See Also:
      API Note:
      Subclasses may override this to prevent or restrict pathfinding through the block. For example, DoorBlock restricts it to open doors only.
      Mappings:
      Namespace Name Mixin selector
      named canPathfindThrough Lnet/minecraft/block/AbstractBlock;canPathfindThrough(Lnet/minecraft/block/BlockState;Lnet/minecraft/entity/ai/pathing/NavigationType;)Z
      intermediary method_9516 Lnet/minecraft/class_4970;method_9516(Lnet/minecraft/class_2680;Lnet/minecraft/class_10;)Z
      official a Ldsc;a(Ldsd;Leol;)Z