Importing the class

Link to importing-the-class

It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.

ZenScript
Copy
import crafttweaker.api.world.LevelReader;

Implemented Interfaces

Link to implemented-interfaces

LevelReader implements the following interfaces. That means all methods defined in these interfaces are also available in LevelReader

Link to canSeeSkyFromBelowWater

Name: canSeeSkyFromBelowWater

Return Type: boolean

ZenScript
Copy
LevelReader.canSeeSkyFromBelowWater(pos as BlockPos) as boolean
ParameterType
Parameter
pos
Type
BlockPos

Name: getBiome

Gets the biome at a given position.

Returns: The biome at the given position.
Return Type: Biome

ZenScript
Copy
// LevelReader.getBiome(pos as BlockPos) as Biome

myLevelReader.getBiome(new BlockPos(0, 1, 2));
ParameterTypeDescription
Parameter
pos
Type
BlockPos
Description
The position to look up.

Name: hasChunk

Return Type: boolean

ZenScript
Copy
LevelReader.hasChunk(x as int, z as int) as boolean
ParameterType
Parameter
x
Type
int
Parameter
z
Type
int

Name: isEmptyBlock

Checks if the block at a given position is empty.

Returns: Whether the block is empty.
Return Type: boolean

ZenScript
Copy
// LevelReader.isEmptyBlock(pos as BlockPos) as boolean

myLevelReader.isEmptyBlock(new BlockPos(0, 1, 2));
ParameterTypeDescription
Parameter
pos
Type
BlockPos
Description
The position to look up.

Name: isWaterAt

Return Type: boolean

ZenScript
Copy
LevelReader.isWaterAt(pos as BlockPos) as boolean
ParameterType
Parameter
pos
Type
BlockPos
NameTypeHas GetterHas SetterDescription
Name
isClientSide
Type
boolean
Has Getter
true
Has Setter
false
Description
Name
seaLevel
Type
int
Has Getter
true
Has Setter
false
Description
Gets the height of the sea level.
Name
skyDarken
Type
int
Has Getter
true
Has Setter
false
Description