Package net.minecraft.block.entity
Class LockableContainerBlockEntity
java.lang.Object
net.minecraft.block.entity.BlockEntity
net.minecraft.block.entity.LockableContainerBlockEntity
- All Implemented Interfaces:
Inventory
,NamedScreenHandlerFactory
,ScreenHandlerFactory
,Clearable
,Nameable
- Direct Known Subclasses:
AbstractFurnaceBlockEntity
,BrewingStandBlockEntity
,LootableContainerBlockEntity
public abstract class LockableContainerBlockEntity extends BlockEntity implements Inventory, NamedScreenHandlerFactory, Nameable
- Mappings:
Namespace Name official cfl
intermediary net/minecraft/class_2624
named net/minecraft/block/entity/LockableContainerBlockEntity
-
Field Summary
Fields Modifier and Type Field Description private Text
customName
private ContainerLock
lock
Fields inherited from class net.minecraft.block.entity.BlockEntity
pos, removed, world
-
Constructor Summary
Constructors Modifier Constructor Description protected
LockableContainerBlockEntity(BlockEntityType<?> type, BlockPos pos, BlockState state)
-
Method Summary
Modifier and Type Method Description boolean
checkUnlocked(PlayerEntity player)
static boolean
checkUnlocked(PlayerEntity player, ContainerLock lock, Text containerName)
ScreenHandler
createMenu(int syncId, PlayerInventory inv, PlayerEntity player)
protected abstract ScreenHandler
createScreenHandler(int syncId, PlayerInventory playerInventory)
void
fromTag(CompoundTag tag)
protected abstract Text
getContainerName()
Text
getCustomName()
Text
getDisplayName()
Returns the title of this screen handler; will be a part of the open screen packet sent to the client.Text
getName()
void
setCustomName(Text customName)
CompoundTag
toTag(CompoundTag tag)
Methods inherited from class net.minecraft.block.entity.BlockEntity
cancelRemoval, copyItemDataRequiresOperator, createFromTag, getCachedState, getPos, getSquaredRenderDistance, getType, getWorld, hasWorld, isRemoved, markDirty, markDirty, markRemoved, onSyncedBlockEvent, populateCrashReport, setCachedState, setWorld, toInitialChunkDataTag, toUpdatePacket
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.inventory.Inventory
canPlayerUse, containsAny, count, getMaxCountPerStack, getStack, isEmpty, isValid, markDirty, onClose, onOpen, removeStack, removeStack, setStack, size
Methods inherited from interface net.minecraft.util.Nameable
hasCustomName
-
Field Details
-
lock
- Mappings:
Namespace Name Mixin selector official a
Lcfl;a:Laps;
intermediary field_12045
Lnet/minecraft/class_2624;field_12045:Lnet/minecraft/class_1273;
named lock
Lnet/minecraft/block/entity/LockableContainerBlockEntity;lock:Lnet/minecraft/inventory/ContainerLock;
-
customName
- Mappings:
Namespace Name Mixin selector official b
Lcfl;b:Loi;
intermediary field_17376
Lnet/minecraft/class_2624;field_17376:Lnet/minecraft/class_2561;
named customName
Lnet/minecraft/block/entity/LockableContainerBlockEntity;customName:Lnet/minecraft/text/Text;
-
-
Constructor Details
-
LockableContainerBlockEntity
- Mappings:
Namespace Name Mixin selector official <init>
Lcfr;<init>(Lcft;Lfx;Lcht;)V
intermediary <init>
Lnet/minecraft/class_2586;<init>(Lnet/minecraft/class_2591;Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;)V
named <init>
Lnet/minecraft/block/entity/BlockEntity;<init>(Lnet/minecraft/block/entity/BlockEntityType;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)V
-
-
Method Details
-
fromTag
- Overrides:
fromTag
in classBlockEntity
- Mappings:
Namespace Name Mixin selector official a
Lcfr;a(Lmq;)V
intermediary method_11014
Lnet/minecraft/class_2586;method_11014(Lnet/minecraft/class_2487;)V
named fromTag
Lnet/minecraft/block/entity/BlockEntity;fromTag(Lnet/minecraft/nbt/CompoundTag;)V
-
toTag
- Overrides:
toTag
in classBlockEntity
- Mappings:
Namespace Name Mixin selector official b
Lcfr;b(Lmq;)Lmq;
intermediary method_11007
Lnet/minecraft/class_2586;method_11007(Lnet/minecraft/class_2487;)Lnet/minecraft/class_2487;
named toTag
Lnet/minecraft/block/entity/BlockEntity;toTag(Lnet/minecraft/nbt/CompoundTag;)Lnet/minecraft/nbt/CompoundTag;
-
setCustomName
- Mappings:
Namespace Name Mixin selector official a
Lcfl;a(Loi;)V
intermediary method_17488
Lnet/minecraft/class_2624;method_17488(Lnet/minecraft/class_2561;)V
named setCustomName
Lnet/minecraft/block/entity/LockableContainerBlockEntity;setCustomName(Lnet/minecraft/text/Text;)V
-
getName
-
getDisplayName
Returns the title of this screen handler; will be a part of the open screen packet sent to the client.- Specified by:
getDisplayName
in interfaceNameable
- Specified by:
getDisplayName
in interfaceNamedScreenHandlerFactory
- Mappings:
Namespace Name Mixin selector official d
Lapt;d()Loi;
intermediary method_5476
Lnet/minecraft/class_3908;method_5476()Lnet/minecraft/class_2561;
named getDisplayName
Lnet/minecraft/screen/NamedScreenHandlerFactory;getDisplayName()Lnet/minecraft/text/Text;
-
getCustomName
- Specified by:
getCustomName
in interfaceNameable
- Mappings:
Namespace Name Mixin selector official T
Lapu;T()Loi;
intermediary method_5797
Lnet/minecraft/class_1275;method_5797()Lnet/minecraft/class_2561;
named getCustomName
Lnet/minecraft/util/Nameable;getCustomName()Lnet/minecraft/text/Text;
-
getContainerName
- Mappings:
Namespace Name Mixin selector official g
Lcfl;g()Loi;
intermediary method_17823
Lnet/minecraft/class_2624;method_17823()Lnet/minecraft/class_2561;
named getContainerName
Lnet/minecraft/block/entity/LockableContainerBlockEntity;getContainerName()Lnet/minecraft/text/Text;
-
checkUnlocked
- Mappings:
Namespace Name Mixin selector official d
Lcfl;d(Lbhl;)Z
intermediary method_17489
Lnet/minecraft/class_2624;method_17489(Lnet/minecraft/class_1657;)Z
named checkUnlocked
Lnet/minecraft/block/entity/LockableContainerBlockEntity;checkUnlocked(Lnet/minecraft/entity/player/PlayerEntity;)Z
-
checkUnlocked
- Mappings:
Namespace Name Mixin selector official a
Lcfl;a(Lbhl;Laps;Loi;)Z
intermediary method_17487
Lnet/minecraft/class_2624;method_17487(Lnet/minecraft/class_1657;Lnet/minecraft/class_1273;Lnet/minecraft/class_2561;)Z
named checkUnlocked
Lnet/minecraft/block/entity/LockableContainerBlockEntity;checkUnlocked(Lnet/minecraft/entity/player/PlayerEntity;Lnet/minecraft/inventory/ContainerLock;Lnet/minecraft/text/Text;)Z
-
createMenu
- Specified by:
createMenu
in interfaceScreenHandlerFactory
- Mappings:
Namespace Name Mixin selector official createMenu
Lbkt;createMenu(ILbhk;Lbhl;)Lbjr;
intermediary createMenu
Lnet/minecraft/class_1270;createMenu(ILnet/minecraft/class_1661;Lnet/minecraft/class_1657;)Lnet/minecraft/class_1703;
named createMenu
Lnet/minecraft/screen/ScreenHandlerFactory;createMenu(ILnet/minecraft/entity/player/PlayerInventory;Lnet/minecraft/entity/player/PlayerEntity;)Lnet/minecraft/screen/ScreenHandler;
-
createScreenHandler
- Mappings:
Namespace Name Mixin selector official a
Lcfl;a(ILbhk;)Lbjr;
intermediary method_5465
Lnet/minecraft/class_2624;method_5465(ILnet/minecraft/class_1661;)Lnet/minecraft/class_1703;
named createScreenHandler
Lnet/minecraft/block/entity/LockableContainerBlockEntity;createScreenHandler(ILnet/minecraft/entity/player/PlayerInventory;)Lnet/minecraft/screen/ScreenHandler;
-