ColumnBlockPosition

Represents a 2D block position in a Minecraft world, defined by integer X and Z coordinates.

This is used as the result type for column block position arguments, where the Y coordinate is not specified and must be provided separately.

Example usage in a command:

columnBlockPosition("pos") {
executes { context ->
val resolver = context.getArgument("pos", ColumnBlockPositionResolver::class.java)
val col = resolver.resolve(context.source)
val pos = col.toPosition(64) // supply Y coordinate
1
}
}

Inheritors

Properties

Link copied to clipboard
abstract val blockX: Int

The X coordinate of the column block position.

Link copied to clipboard
abstract val blockZ: Int

The Z coordinate of the column block position.

Functions

Link copied to clipboard
open fun toPosition(y: Int): BlockPosition

Converts this column position to a full BlockPosition by supplying a Y coordinate.