public class ChunkSection
extends java.lang.Object
コンストラクタと説明 |
---|
ChunkSection(int yBaseIn) |
ChunkSection(int yBaseIn,
short blockRefCountIn,
short blockTickRefCountIn,
short fluidRefCountIn) |
修飾子とタイプ | メソッドと説明 |
---|---|
boolean |
contains(BlockState state) |
BlockState |
getBlockState(int x,
int y,
int z) |
PalettedContainer<BlockState> |
getData() |
IFluidState |
getFluidState(int x,
int y,
int z) |
int |
getSize() |
int |
getYLocation()
Gets the y coordinate that this chunk section starts at (which is a multiple of 16).
|
boolean |
isEmpty()
Returns whether or not this block storage's Chunk is fully empty, based on its internal reference count.
|
static boolean |
isEmpty(ChunkSection section) |
void |
lock() |
boolean |
needsRandomTick()
Returns whether or not this block storage's Chunk will require random ticking, used to avoid looping through
random block ticks when there are no blocks that would randomly tick.
|
boolean |
needsRandomTickAny() |
boolean |
needsRandomTickFluid() |
void |
read(PacketBuffer packetBufferIn) |
void |
recalculateRefCounts() |
BlockState |
setBlockState(int x,
int y,
int z,
BlockState blockStateIn) |
BlockState |
setBlockState(int x,
int y,
int z,
BlockState state,
boolean useLocks) |
void |
unlock() |
void |
write(PacketBuffer packetBufferIn) |
public ChunkSection(int yBaseIn)
public ChunkSection(int yBaseIn, short blockRefCountIn, short blockTickRefCountIn, short fluidRefCountIn)
public BlockState getBlockState(int x, int y, int z)
public IFluidState getFluidState(int x, int y, int z)
public void lock()
public void unlock()
public BlockState setBlockState(int x, int y, int z, BlockState blockStateIn)
public BlockState setBlockState(int x, int y, int z, BlockState state, boolean useLocks)
public boolean isEmpty()
public static boolean isEmpty(@Nullable ChunkSection section)
public boolean needsRandomTickAny()
public boolean needsRandomTick()
public boolean needsRandomTickFluid()
public int getYLocation()
section.getYLocation() >> 4
. Note that there is a section below the world for lighting purposes.public void recalculateRefCounts()
public PalettedContainer<BlockState> getData()
public void read(PacketBuffer packetBufferIn)
public void write(PacketBuffer packetBufferIn)
public int getSize()
public boolean contains(BlockState state)