Class CommandBlockBlockEntity

java.lang.Object
net.minecraft.block.entity.BlockEntity
net.minecraft.block.entity.CommandBlockBlockEntity

public class CommandBlockBlockEntity extends BlockEntity
Mappings:
Namespace Name
named net/minecraft/block/entity/CommandBlockBlockEntity
intermediary net/minecraft/class_2593
official dvg
  • Field Details

    • powered

      private boolean powered
      Mappings:
      Namespace Name Mixin selector
      named powered Lnet/minecraft/block/entity/CommandBlockBlockEntity;powered:Z
      intermediary field_11919 Lnet/minecraft/class_2593;field_11919:Z
      official a Ldvg;a:Z
    • auto

      private boolean auto
      Mappings:
      Namespace Name Mixin selector
      named auto Lnet/minecraft/block/entity/CommandBlockBlockEntity;auto:Z
      intermediary field_11918 Lnet/minecraft/class_2593;field_11918:Z
      official b Ldvg;b:Z
    • conditionMet

      private boolean conditionMet
      Mappings:
      Namespace Name Mixin selector
      named conditionMet Lnet/minecraft/block/entity/CommandBlockBlockEntity;conditionMet:Z
      intermediary field_11917 Lnet/minecraft/class_2593;field_11917:Z
      official c Ldvg;c:Z
    • commandExecutor

      private final CommandBlockExecutor commandExecutor
      Mappings:
      Namespace Name Mixin selector
      named commandExecutor Lnet/minecraft/block/entity/CommandBlockBlockEntity;commandExecutor:Lnet/minecraft/world/CommandBlockExecutor;
      intermediary field_11920 Lnet/minecraft/class_2593;field_11920:Lnet/minecraft/class_1918;
      official d Ldvg;d:Ldgh;
  • Constructor Details

    • CommandBlockBlockEntity

      public CommandBlockBlockEntity(BlockPos pos, BlockState state)
      Mappings:
      Namespace Name Mixin selector
      named <init> Lnet/minecraft/block/entity/CommandBlockBlockEntity;<init>(Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)V
      intermediary <init> Lnet/minecraft/class_2593;<init>(Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;)V
      official <init> Ldvg;<init>(Ljh;Ldxu;)V
  • Method Details

    • writeNbt

      protected void writeNbt(NbtCompound nbt, RegistryWrapper.WrapperLookup registries)
      Writes data to nbt. Subclasses should override this if they store a persistent data.

      NBT is a storage format; therefore, a data from NBT is loaded to a block entity instance's fields, which are used for other operations instead of the NBT. The data is written back to NBT when saving the block entity.

      Overrides:
      writeNbt in class BlockEntity
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named writeNbt Lnet/minecraft/block/entity/BlockEntity;writeNbt(Lnet/minecraft/nbt/NbtCompound;Lnet/minecraft/registry/RegistryWrapper$WrapperLookup;)V
      intermediary method_11007 Lnet/minecraft/class_2586;method_11007(Lnet/minecraft/class_2487;Lnet/minecraft/class_7225$class_7874;)V
      official b Lduw;b(Lux;Ljs$a;)V
    • readNbt

      protected void readNbt(NbtCompound nbt, RegistryWrapper.WrapperLookup registries)
      Reads data from nbt. Subclasses should override this if they store a persistent data.

      NBT is a storage format; therefore, a data from NBT is loaded to a block entity instance's fields, which are used for other operations instead of the NBT. The data is written back to NBT when saving the block entity.

      nbt might not have all expected keys, or might have a key whose value does not meet the requirement (such as the type or the range). This method should fall back to a reasonable default value instead of throwing an exception.

      Overrides:
      readNbt in class BlockEntity
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named readNbt Lnet/minecraft/block/entity/BlockEntity;readNbt(Lnet/minecraft/nbt/NbtCompound;Lnet/minecraft/registry/RegistryWrapper$WrapperLookup;)V
      intermediary method_11014 Lnet/minecraft/class_2586;method_11014(Lnet/minecraft/class_2487;Lnet/minecraft/class_7225$class_7874;)V
      official a Lduw;a(Lux;Ljs$a;)V
    • copyItemDataRequiresOperator

      public boolean copyItemDataRequiresOperator()
      Returns whether the block item should require the player to have operator permissions to copy the block entity data on placement.

      Block entities that can execute commands should override this to return true.

      Overrides:
      copyItemDataRequiresOperator in class BlockEntity
      Returns:
      whether the block item should require the player to have operator permissions to copy the block entity data on placement
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named copyItemDataRequiresOperator Lnet/minecraft/block/entity/BlockEntity;copyItemDataRequiresOperator()Z
      intermediary method_11011 Lnet/minecraft/class_2586;method_11011()Z
      official p Lduw;p()Z
    • getCommandExecutor

      public CommandBlockExecutor getCommandExecutor()
      Mappings:
      Namespace Name Mixin selector
      named getCommandExecutor Lnet/minecraft/block/entity/CommandBlockBlockEntity;getCommandExecutor()Lnet/minecraft/world/CommandBlockExecutor;
      intermediary method_11040 Lnet/minecraft/class_2593;method_11040()Lnet/minecraft/class_1918;
      official b Ldvg;b()Ldgh;
    • setPowered

      public void setPowered(boolean powered)
      Mappings:
      Namespace Name Mixin selector
      named setPowered Lnet/minecraft/block/entity/CommandBlockBlockEntity;setPowered(Z)V
      intermediary method_11038 Lnet/minecraft/class_2593;method_11038(Z)V
      official a Ldvg;a(Z)V
    • isPowered

      public boolean isPowered()
      Mappings:
      Namespace Name Mixin selector
      named isPowered Lnet/minecraft/block/entity/CommandBlockBlockEntity;isPowered()Z
      intermediary method_11043 Lnet/minecraft/class_2593;method_11043()Z
      official c Ldvg;c()Z
    • isAuto

      public boolean isAuto()
      Mappings:
      Namespace Name Mixin selector
      named isAuto Lnet/minecraft/block/entity/CommandBlockBlockEntity;isAuto()Z
      intermediary method_11042 Lnet/minecraft/class_2593;method_11042()Z
      official d Ldvg;d()Z
    • setAuto

      public void setAuto(boolean auto)
      Mappings:
      Namespace Name Mixin selector
      named setAuto Lnet/minecraft/block/entity/CommandBlockBlockEntity;setAuto(Z)V
      intermediary method_11041 Lnet/minecraft/class_2593;method_11041(Z)V
      official b Ldvg;b(Z)V
    • updateCommandBlock

      public void updateCommandBlock()
      Mappings:
      Namespace Name Mixin selector
      named updateCommandBlock Lnet/minecraft/block/entity/CommandBlockBlockEntity;updateCommandBlock()V
      intermediary method_23359 Lnet/minecraft/class_2593;method_23359()V
      official f Ldvg;f()V
    • scheduleAutoTick

      private void scheduleAutoTick()
      Mappings:
      Namespace Name Mixin selector
      named scheduleAutoTick Lnet/minecraft/block/entity/CommandBlockBlockEntity;scheduleAutoTick()V
      intermediary method_23360 Lnet/minecraft/class_2593;method_23360()V
      official v Ldvg;v()V
    • isConditionMet

      public boolean isConditionMet()
      Mappings:
      Namespace Name Mixin selector
      named isConditionMet Lnet/minecraft/block/entity/CommandBlockBlockEntity;isConditionMet()Z
      intermediary method_11044 Lnet/minecraft/class_2593;method_11044()Z
      official j Ldvg;j()Z
    • updateConditionMet

      public boolean updateConditionMet()
      Mappings:
      Namespace Name Mixin selector
      named updateConditionMet Lnet/minecraft/block/entity/CommandBlockBlockEntity;updateConditionMet()Z
      intermediary method_11045 Lnet/minecraft/class_2593;method_11045()Z
      official k Ldvg;k()Z
    • getCommandBlockType

      public CommandBlockBlockEntity.Type getCommandBlockType()
      Mappings:
      Namespace Name Mixin selector
      named getCommandBlockType Lnet/minecraft/block/entity/CommandBlockBlockEntity;getCommandBlockType()Lnet/minecraft/block/entity/CommandBlockBlockEntity$Type;
      intermediary method_11039 Lnet/minecraft/class_2593;method_11039()Lnet/minecraft/class_2593$class_2594;
      official t Ldvg;t()Ldvg$a;
    • isConditionalCommandBlock

      public boolean isConditionalCommandBlock()
      Mappings:
      Namespace Name Mixin selector
      named isConditionalCommandBlock Lnet/minecraft/block/entity/CommandBlockBlockEntity;isConditionalCommandBlock()Z
      intermediary method_11046 Lnet/minecraft/class_2593;method_11046()Z
      official u Ldvg;u()Z
    • readComponents

      protected void readComponents(BlockEntity.ComponentsAccess components)
      Overrides:
      readComponents in class BlockEntity
      Mappings:
      Namespace Name Mixin selector
      named readComponents Lnet/minecraft/block/entity/BlockEntity;readComponents(Lnet/minecraft/block/entity/BlockEntity$ComponentsAccess;)V
      intermediary method_57568 Lnet/minecraft/class_2586;method_57568(Lnet/minecraft/class_2586$class_9473;)V
      official a Lduw;a(Lduw$b;)V
    • addComponents

      protected void addComponents(ComponentMap.Builder builder)
      Overrides:
      addComponents in class BlockEntity
      Mappings:
      Namespace Name Mixin selector
      named addComponents Lnet/minecraft/block/entity/BlockEntity;addComponents(Lnet/minecraft/component/ComponentMap$Builder;)V
      intermediary method_57567 Lnet/minecraft/class_2586;method_57567(Lnet/minecraft/class_9323$class_9324;)V
      official a Lduw;a(Lkq$a;)V
    • removeFromCopiedStackNbt

      public void removeFromCopiedStackNbt(NbtCompound nbt)
      Overrides:
      removeFromCopiedStackNbt in class BlockEntity
      Mappings:
      Namespace Name Mixin selector
      named removeFromCopiedStackNbt Lnet/minecraft/block/entity/BlockEntity;removeFromCopiedStackNbt(Lnet/minecraft/nbt/NbtCompound;)V
      intermediary method_57569 Lnet/minecraft/class_2586;method_57569(Lnet/minecraft/class_2487;)V
      official a Lduw;a(Lux;)V