Package net.hollowcube.polar
Class PolarSection
java.lang.Object
net.hollowcube.polar.PolarSection
Representation of the latest version of the section format.
Marked as internal because of the use of mutable arrays. These arrays must _not_ be mutated. This class should be considered immutable.
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final int -
Constructor Summary
ConstructorsConstructorDescriptionPolarSection(String @NotNull [] blockPalette, int @Nullable [] blockData, String @NotNull [] biomePalette, int @Nullable [] biomeData, @NotNull PolarSection.LightContent blockLightContent, byte @Nullable [] blockLight, @NotNull PolarSection.LightContent skyLightContent, byte @Nullable [] skyLight) -
Method Summary
Modifier and TypeMethodDescriptionint[]Returns the uncompressed palette data.@NotNull String @NotNull []int[]Returns the uncompressed palette data.byte[]@NotNull PolarSection.LightContent@NotNull String @NotNull []booleanisEmpty()byte[]skyLight()@NotNull PolarSection.LightContent
-
Field Details
-
BLOCK_PALETTE_SIZE
public static final int BLOCK_PALETTE_SIZE- See Also:
-
BIOME_PALETTE_SIZE
public static final int BIOME_PALETTE_SIZE- See Also:
-
-
Constructor Details
-
PolarSection
public PolarSection() -
PolarSection
public PolarSection(String @NotNull [] blockPalette, int @Nullable [] blockData, String @NotNull [] biomePalette, int @Nullable [] biomeData, @NotNull @NotNull PolarSection.LightContent blockLightContent, byte @Nullable [] blockLight, @NotNull @NotNull PolarSection.LightContent skyLightContent, byte @Nullable [] skyLight)
-
-
Method Details
-
isEmpty
public boolean isEmpty() -
blockPalette
-
blockData
public int[] blockData()Returns the uncompressed palette data. Each int corresponds to an index in the palette. Always has a length of 4096. -
biomePalette
-
biomeData
public int[] biomeData()Returns the uncompressed palette data. Each int corresponds to an index in the palette. Always has a length of 256. -
blockLightContent
-
blockLight
public byte[] blockLight() -
skyLightContent
-
skyLight
public byte[] skyLight()
-