public final class DeathChestsState
extends net.minecraft.world.PersistentState
| Modifier and Type | Method and Description |
|---|---|
void |
addDeathChest(DeathChest deathChest)
Adds an existing death chest.
|
void |
fromTag(net.minecraft.nbt.CompoundTag tag) |
static DeathChestsState |
get(net.minecraft.server.world.ServerWorld world)
Returns the
DeathChestsState instance for the specified world. |
@Nullable DeathChest |
getDeathChest(UUID identifier)
Returns the death chest with the specified identifier.
|
Set<UUID> |
getDeathChestIdentifiers()
Returns the identifiers of all placed death chests.
|
Set<String> |
getDeathChestIdentifierStrings()
Returns the identifier strings of all placed death chests.
|
Collection<DeathChest> |
getDeathChests()
Returns all placed death chests.
|
@Nullable DeathChest |
getExistingDeathChest(net.minecraft.util.math.BlockPos pos)
Returns the existing death chest at the specified position.
|
Collection<DeathChest> |
getExistingDeathChests()
Returns all existing death chests.
|
Queue<DeathChest> |
getQueuedDeathChests()
Returns a queue of all unplaced death chests.
|
static void |
onBlockEntityUnload(net.minecraft.block.entity.BlockEntity blockEntity,
net.minecraft.server.world.ServerWorld world)
Called when a block entity is unloaded.
|
net.minecraft.nbt.CompoundTag |
toTag(net.minecraft.nbt.CompoundTag tag) |
public void fromTag(net.minecraft.nbt.CompoundTag tag)
fromTag in class net.minecraft.world.PersistentStatepublic net.minecraft.nbt.CompoundTag toTag(net.minecraft.nbt.CompoundTag tag)
toTag in class net.minecraft.world.PersistentStatepublic Set<UUID> getDeathChestIdentifiers()
public Set<String> getDeathChestIdentifierStrings()
Set of strings.public Collection<DeathChest> getDeathChests()
Collection of all placed death chests.public @Nullable DeathChest getDeathChest(UUID identifier)
identifier - an identifier.DeathChest with the specified identifier.public Collection<DeathChest> getExistingDeathChests()
Collection of all existing death chests.public @Nullable DeathChest getExistingDeathChest(net.minecraft.util.math.BlockPos pos)
pos - a position.DeathChest at the specified BlockPos,
or null if it does not exist.public void addDeathChest(DeathChest deathChest)
deathChest - a DeathChest.public Queue<DeathChest> getQueuedDeathChests()
public static DeathChestsState get(net.minecraft.server.world.ServerWorld world)
DeathChestsState instance for the specified world.world - a ServerWorld.DeathChestsState instance for the specified world.public static void onBlockEntityUnload(net.minecraft.block.entity.BlockEntity blockEntity,
net.minecraft.server.world.ServerWorld world)
blockEntity - a BlockEntity.world - a ServerWorld.