Class CloudChunkSection

java.lang.Object
org.cloudburstmc.server.level.chunk.CloudChunkSection
All Implemented Interfaces:
org.cloudburstmc.api.level.chunk.ChunkSection

public class CloudChunkSection extends Object implements org.cloudburstmc.api.level.chunk.ChunkSection
  • Field Details

  • Constructor Details

    • CloudChunkSection

      public CloudChunkSection()
    • CloudChunkSection

      public CloudChunkSection(BlockStorage[] blockStorage)
    • CloudChunkSection

      public CloudChunkSection(BlockStorage[] storage, byte[] blockLight, byte[] skyLight)
  • Method Details

    • blockIndex

      public static int blockIndex(int x, int y, int z)
    • checkBounds

      public static void checkBounds(int x, int y, int z)
    • getBlock

      public org.cloudburstmc.api.block.BlockState getBlock(int x, int y, int z, int layer)
      Specified by:
      getBlock in interface org.cloudburstmc.api.level.chunk.ChunkSection
    • setBlock

      public void setBlock(int x, int y, int z, int layer, org.cloudburstmc.api.block.BlockState blockState)
      Specified by:
      setBlock in interface org.cloudburstmc.api.level.chunk.ChunkSection
    • getSkyLight

      public byte getSkyLight(int x, int y, int z)
      Specified by:
      getSkyLight in interface org.cloudburstmc.api.level.chunk.ChunkSection
    • setSkyLight

      public void setSkyLight(int x, int y, int z, byte val)
      Specified by:
      setSkyLight in interface org.cloudburstmc.api.level.chunk.ChunkSection
    • getBlockLight

      public byte getBlockLight(int x, int y, int z)
      Specified by:
      getBlockLight in interface org.cloudburstmc.api.level.chunk.ChunkSection
    • setBlockLight

      public void setBlockLight(int x, int y, int z, byte val)
      Specified by:
      setBlockLight in interface org.cloudburstmc.api.level.chunk.ChunkSection
    • writeToNetwork

      public void writeToNetwork(io.netty.buffer.ByteBuf buffer)
    • getSkyLightArray

      public NibbleArray getSkyLightArray()
    • getBlockLightArray

      public NibbleArray getBlockLightArray()
    • getBlockStorageArray

      public BlockStorage[] getBlockStorageArray()
    • isEmpty

      public boolean isEmpty()
    • copy

      public CloudChunkSection copy()