public class BlockChunk implements Component
Class BlockChunk. Provides blockchunk functionality for the Hytale server.
java.lang.Object > BlockChunk
Field Summary
index
Field index.
x
Field x.
z
Field z.
chunkSections
Field chunkSections.
migratedChunkSections
Field migratedChunkSections.
environments
Field environments.
needsPhysics
Field needsPhysics.
needsSaving
Field needsSaving.
section
Field section.
blockId
Field blockId.
type
Field type.
column
Field column.
sections
Field sections.
sectionIndex
Field sectionIndex.
changed
Field changed.
map
Field map.
count
Field count.
set
Field set.
wx
Field wx.
wz
Field wz.
wy
Field wy.
out
Field out.
old
Field old.
temp
Field temp.
buf
Field buf.
ref
Field ref.
packet
Field packet.
component
Field component.
Method Detail
getComponentType
BlockChunk>
getComponentType
()
Method getComponentType.
BlockChunk
private
BlockChunk
()
Method BlockChunk.
ShortBytePalette
new
ShortBytePalette
()
Method ShortBytePalette.
IntBytePalette
new
IntBytePalette
()
Method IntBytePalette.
EnvironmentChunk
new
EnvironmentChunk
()
Method EnvironmentChunk.
load
void
load
(final int x, final int z)
Method load.
- Parameters:
final intxfinal intz
getIndex
long
getIndex
()
Method getIndex.
getX
int
getX
()
Method getX.
getZ
int
getZ
()
Method getZ.
getHeight
short
getHeight
(final int x, final int z)
Method getHeight.
- Parameters:
final intxfinal intz
setHeight
void
setHeight
(final int x, final int z, final short height)
Method setHeight.
- Parameters:
final intxfinal intzfinal shortheight
updateHeightmap
void
updateHeightmap
()
Method updateHeightmap.
updateHeight
short
updateHeight
(final int x, final int z)
Method updateHeight.
- Parameters:
final intxfinal intz
getSectionAtIndex
Method getSectionAtIndex.
- Parameters:
final intindex
getSectionAtBlockY
Method getSectionAtBlockY.
- Parameters:
final inty
getChunkSections
BlockSection[]
getChunkSections
()
Method getChunkSections.
getSectionCount
int
getSectionCount
()
Method getSectionCount.
getTint
int
getTint
(final int x, final int z)
Method getTint.
- Parameters:
final intxfinal intz
setTint
void
setTint
(final int x, final int z, final int tint)
Method setTint.
- Parameters:
final intxfinal intzfinal inttint
getEnvironmentColumn
Method getEnvironmentColumn.
- Parameters:
final intxfinal intz
setEnvironment
void
setEnvironment
(final int x, final int y, final int z, final int environment)
Method setEnvironment.
- Parameters:
final intxfinal intyfinal intzfinal intenvironment
getRedBlockLight
byte
getRedBlockLight
(final int x, final int y, final int z)
Method getRedBlockLight.
- Parameters:
final intxfinal intyfinal intz
getGreenBlockLight
byte
getGreenBlockLight
(final int x, final int y, final int z)
Method getGreenBlockLight.
- Parameters:
final intxfinal intyfinal intz
getBlueBlockLight
byte
getBlueBlockLight
(final int x, final int y, final int z)
Method getBlueBlockLight.
- Parameters:
final intxfinal intyfinal intz
getBlockLight
short
getBlockLight
(final int x, final int y, final int z)
Method getBlockLight.
- Parameters:
final intxfinal intyfinal intz
getSkyLight
byte
getSkyLight
(final int x, final int y, final int z)
Method getSkyLight.
- Parameters:
final intxfinal intyfinal intz
getBlockLightIntensity
byte
getBlockLightIntensity
(final int x, final int y, final int z)
Method getBlockLightIntensity.
- Parameters:
final intxfinal intyfinal intz
getBlock
int
getBlock
(final int x, final int y, final int z)
Method getBlock.
- Parameters:
final intxfinal intyfinal intz
setBlock
boolean
setBlock
(final int x, final int y, final int z, final int blockId, final int rotation, final int filler)
Method setBlock.
- Parameters:
final intxfinal intyfinal intzfinal intblockIdfinal introtationfinal intfiller
contains
boolean
contains
(final int blockId)
Method contains.
- Parameters:
final intblockId
count
int
count
(final int blockId)
Method count.
- Parameters:
final intblockId
blockCounts
Int2IntMap
blockCounts
()
Method blockCounts.
blocks
IntSet
blocks
()
Method blocks.
blockCount
int
blockCount
()
Method blockCount.
preTick
void
preTick
(final Instant gameTime)
Method preTick.
- Parameters:
final InstantgameTime
forEachTicking
Method forEachTicking.
- Parameters:
final Ttfinal Vvfinal ObjectPositionBlockFunctionacceptor
mergeTickingBlocks
void
mergeTickingBlocks
()
Method mergeTickingBlocks.
setTicking
boolean
setTicking
(final int x, final int y, final int z, final boolean ticking)
Method setTicking.
- Parameters:
final intxfinal intyfinal intzfinal booleanticking
isTicking
boolean
isTicking
(final int x, final int y, final int z)
Method isTicking.
- Parameters:
final intxfinal intyfinal intz
getTickingBlocksCount
int
getTickingBlocksCount
()
Method getTickingBlocksCount.
setNeighbourBlocksTicking
boolean
setNeighbourBlocksTicking
(final int x, final int y, final int z)
Method setNeighbourBlocksTicking.
- Parameters:
final intxfinal intyfinal intz
markNeedsSaving
void
markNeedsSaving
()
Method markNeedsSaving.
getNeedsSaving
boolean
getNeedsSaving
()
Method getNeedsSaving.
consumeNeedsSaving
boolean
consumeNeedsSaving
()
Method consumeNeedsSaving.
markNeedsPhysics
void
markNeedsPhysics
()
Method markNeedsPhysics.
consumeNeedsPhysics
boolean
consumeNeedsPhysics
()
Method consumeNeedsPhysics.
invalidateChunkSection
void
invalidateChunkSection
(final int sectionIndex)
Method invalidateChunkSection.
- Parameters:
final intsectionIndex
takeMigratedSections
BlockSection[]
takeMigratedSections
()
Method takeMigratedSections.
getMigratedSections
BlockSection[]
getMigratedSections
()
Method getMigratedSections.
deserialize
Method deserialize.
- Parameters:
@Nonnull final byte[]bytes@Nonnull final ExtraInfoextraInfo
getCachedHeightmapPacket
CompletableFuture>
getCachedHeightmapPacket
()
Method getCachedHeightmapPacket.
SetChunkHeightmap
new
SetChunkHeightmap
(this.x, this.z, this.height.serialize()
Method SetChunkHeightmap.
- Parameters:
this.xthis.xthis.zthis.zthis.height.serialize(this.height.serialize(
getCachedTintsPacket
CompletableFuture>
getCachedTintsPacket
()
Method getCachedTintsPacket.
SetChunkTintmap
new
SetChunkTintmap
(this.x, this.z, this.tint.serialize()
Method SetChunkTintmap.
- Parameters:
this.xthis.xthis.zthis.zthis.tint.serialize(this.tint.serialize(
getCachedEnvironmentsPacket
CompletableFuture>
getCachedEnvironmentsPacket
()
Method getCachedEnvironmentsPacket.
SetChunkEnvironments
new
SetChunkEnvironments
(this.x, this.z, this.environments.serializeProtocol()
Method SetChunkEnvironments.
- Parameters:
this.xthis.xthis.zthis.zthis.environments.serializeProtocol(this.environments.serializeProtocol(
LoadBlockChunkPacketSystem
Method LoadBlockChunkPacketSystem.
- Parameters:
final ComponentTypeblockChunkComponentType
fetch
void
fetch
(final int index, @Nonnull final ArchetypeChunk archetypeChunk, final Store store, final CommandBuffer commandBuffer, final PlayerRef player, @Nonnull final List> results)
Method fetch.
- Parameters:
final intindex@Nonnull final ArchetypeChunkarchetypeChunkfinal Storestorefinal CommandBuffercommandBufferfinal PlayerRefplayer@Nonnull final Listresults>
chunk
set
chunk
(%d, %d)
Method chunk.
- Parameters:
%d%d