world
The loaded world. Every function returns nil when there is none.
Functions
7 functions. Signatures are generated from the client, so they describe the build you are running.
world.getBlock(x:number, y:number, z:number) -> stringRegistry id, e.g. 'minecraft:obsidian'.
world.isAir(x:number, y:number, z:number) -> booleanworld.isSolid(x:number, y:number, z:number) -> booleanWhether the block has a full collision box.
world.blockHardness(x:number, y:number, z:number) -> number-1 for unbreakable blocks such as bedrock.
world.getTime() -> numberWorld time in ticks.
world.getDimension() -> stringworld.raycast(distance:number) -> table|nilCasts from the player's eye along their look vector. Returns {x, y, z, side, block} for a block hit, or nil for a miss. Blocks only in v1; entity hits report as a miss.