public class EmptyChunk extends WorldChunk
WorldChunk.CreationType
Modifier and Type | Field and Description |
---|---|
private static Biome[] |
BIOMES |
EMPTY_SECTION
Constructor and Description |
---|
EmptyChunk(World world,
ChunkPos pos) |
Modifier and Type | Method and Description |
---|---|
void |
addBlockEntity(BlockEntity blockEntity) |
void |
addEntity(Entity entity) |
boolean |
areSectionsEmptyBetween(int lowerHeight,
int upperHeight) |
<T extends Entity> |
collectEntitiesByClass(Class<? extends T> entityClass,
Box box,
List<T> result,
Predicate<? super T> predicate)
Collects a list of entities of some runtime type and appends them to the given list.
|
void |
collectOtherEntities(Entity except,
Box box,
List<Entity> entityList,
Predicate<? super Entity> predicate) |
BlockEntity |
getBlockEntity(BlockPos pos,
WorldChunk.CreationType creationType) |
BlockState |
getBlockState(BlockPos pos) |
FluidState |
getFluidState(BlockPos pos) |
ChunkHolder.LevelType |
getLevelType() |
LightingProvider |
getLightingProvider() |
int |
getLuminance(BlockPos pos) |
boolean |
isEmpty() |
void |
markDirty() |
void |
remove(Entity entity) |
void |
remove(Entity entity,
int section) |
void |
removeBlockEntity(BlockPos pos) |
void |
setBlockEntity(BlockPos pos,
BlockEntity blockEntity) |
BlockState |
setBlockState(BlockPos pos,
BlockState state,
boolean moved) |
addPendingBlockEntityTag, addStructureReference, collectEntities, disableTickSchedulers, enableTickSchedulers, getBiomeArray, getBlockEntities, getBlockEntity, getBlockEntityPositions, getBlockEntityTag, getBlockTickScheduler, getEntitySectionArray, getFluidState, getFluidTickScheduler, getHeightmap, getHeightmaps, getInhabitedTime, getLightSourcesStream, getPackedBlockEntityTag, getPos, getPostProcessingLists, getSectionArray, getStatus, getStructureReferences, getStructureReferences, getStructureStart, getStructureStarts, getUpgradeData, getWorld, isLightOn, loadFromPacket, loadToWorld, needsSaving, runPostProcessing, sampleHeightmap, setHeightmap, setInhabitedTime, setLastSaveTime, setLevelTypeProvider, setLightOn, setLoadedToWorld, setShouldSave, setStructureReferences, setStructureStart, setStructureStarts, setUnsaved
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getHighestNonEmptySection, getHighestNonEmptySectionYOffset, getList, markBlockForPostProcessing, markBlockForPostProcessing
getDismountHeight, getDismountHeight, getHeight, getMaxLightLevel, method_29546, raycast, raycast, raycastBlock
private static final Biome[] BIOMES
public BlockState getBlockState(BlockPos pos)
getBlockState
in interface BlockView
getBlockState
in class WorldChunk
@Nullable public BlockState setBlockState(BlockPos pos, BlockState state, boolean moved)
setBlockState
in interface Chunk
setBlockState
in class WorldChunk
public FluidState getFluidState(BlockPos pos)
getFluidState
in interface BlockView
getFluidState
in class WorldChunk
@Nullable public LightingProvider getLightingProvider()
getLightingProvider
in class WorldChunk
public int getLuminance(BlockPos pos)
public void addEntity(Entity entity)
addEntity
in interface Chunk
addEntity
in class WorldChunk
public void remove(Entity entity)
remove
in class WorldChunk
public void remove(Entity entity, int section)
remove
in class WorldChunk
@Nullable public BlockEntity getBlockEntity(BlockPos pos, WorldChunk.CreationType creationType)
getBlockEntity
in class WorldChunk
public void addBlockEntity(BlockEntity blockEntity)
addBlockEntity
in class WorldChunk
public void setBlockEntity(BlockPos pos, BlockEntity blockEntity)
setBlockEntity
in interface Chunk
setBlockEntity
in class WorldChunk
public void removeBlockEntity(BlockPos pos)
removeBlockEntity
in interface Chunk
removeBlockEntity
in class WorldChunk
public void markDirty()
markDirty
in class WorldChunk
public void collectOtherEntities(@Nullable Entity except, Box box, List<Entity> entityList, Predicate<? super Entity> predicate)
collectOtherEntities
in class WorldChunk
public <T extends Entity> void collectEntitiesByClass(Class<? extends T> entityClass, Box box, List<T> result, Predicate<? super T> predicate)
collectEntitiesByClass
in class WorldChunk
entityClass
- the class object representing the type collected entities must extendbox
- the box in which to collect entitiesresult
- a list in which to store the collected entitiespredicate
- a predicate which entities must satisfy in order to be collectedpublic boolean isEmpty()
isEmpty
in class WorldChunk
public boolean areSectionsEmptyBetween(int lowerHeight, int upperHeight)
public ChunkHolder.LevelType getLevelType()
getLevelType
in class WorldChunk