Interface IChunkGet

All Superinterfaces:
IBlocks, InputExtent, ITileInput, Trimable
All Known Subinterfaces:
IChunk, IQueueChunk<T>
All Known Implementing Classes:
CharGetBlocks, ChunkHolder, NullChunk, NullChunkGet

public interface IChunkGet extends IBlocks, Trimable, InputExtent, ITileInput
An interface for getting blocks.
  • Method Details

    • getFullBlock

      BaseBlock getFullBlock(int x, int y, int z)
      Specified by:
      getFullBlock in interface InputExtent
    • getBiomeType

      BiomeType getBiomeType(int x, int y, int z)
      Specified by:
      getBiomeType in interface IBlocks
      Specified by:
      getBiomeType in interface InputExtent
    • getBiome

      default BiomeType getBiome(BlockVector3 position)
      Description copied from interface: InputExtent
      Get the biome at the given location.

      If there is no biome available, then the ocean biome should be returned.

      As implementation varies per Minecraft version, this may not exactly get this positions biome. On versions prior to 1.15, this will get the entire column. On later versions it will get the 4x4x4 cube's biome.

      Specified by:
      getBiome in interface InputExtent
      Parameters:
      position - the (x, y, z) location to check the biome at
      Returns:
      the biome at the location
      See Also:
    • getBlock

      BlockState getBlock(int x, int y, int z)
      Specified by:
      getBlock in interface IBlocks
      Specified by:
      getBlock in interface InputExtent
    • getSkyLight

      int getSkyLight(int x, int y, int z)
      Specified by:
      getSkyLight in interface InputExtent
    • getEmittedLight

      int getEmittedLight(int x, int y, int z)
      Specified by:
      getEmittedLight in interface InputExtent
    • getHeightMap

      int[] getHeightMap(HeightMapType type)
      Specified by:
      getHeightMap in interface InputExtent
    • optimize

      default void optimize()
    • call

      <T extends Future<T>> T call(IChunkSet set, Runnable finalize)
    • getEntity

      CompoundTag getEntity(UUID uuid)
    • isCreateCopy

      boolean isCreateCopy()
    • setCreateCopy

      void setCreateCopy(boolean createCopy)
    • getCopy

      @Nullable default IChunkGet getCopy()
    • setLightingToGet

      void setLightingToGet(char[][] lighting, int startSectionIndex, int endSectionIndex)
      Flush the block lighting array (section*blocks) to the chunk GET between the given section indices. Negative allowed.
      Parameters:
      lighting - lighting array
      startSectionIndex - lowest section index
      endSectionIndex - highest section index
    • setSkyLightingToGet

      void setSkyLightingToGet(char[][] lighting, int startSectionIndex, int endSectionIndex)
      Flush the sky lighting array (section*blocks) to the chunk GET between the given section indices. Negative allowed.
      Parameters:
      lighting - sky lighting array
      startSectionIndex - lowest section index
      endSectionIndex - highest section index
    • setHeightmapToGet

      void setHeightmapToGet(HeightMapType type, int[] data)
    • getMaxY

      int getMaxY()
      Max y value for the chunk's world (inclusive)
    • getMinY

      int getMinY()
      Min y value for the chunk's world (inclusive)