Valkyrien Skies Help

How to transform a position from shipyard to world

Learn how to transform a position in the shipyard where blocks on a ship are stored, to world coordinates, where those blocks actually appear.

Before you start

Make sure that:

Transform a shipyard position using Level

Transform a position represented by a Minecraft Vec3

val level: Level = ... val shipPos: Vec3 = ... val worldPos = level.positionToWorld(shipPos)
Level level = ... Vec3 shipPos = ... Vec3 worldPos = ValkyrienSkies.positionToWorld(level, shipPos);

Transform a position represented by a JOML Vector3d

val level: Level = ... val shipPos: Vector3dc = ... val worldPos = level.positionToWorld(shipPos, Vector3d())
Level level = ... Vector3dc shipPos = ... Vector3d worldPos = ValkyrienSkies.positionToWorld(level, shipPos, new Vector3d());

Transform a shipyard position using Ship

Transform a position represented by a Minecraft Vec3

val shipPos: Vec3 = ... val ship: Ship = ... val worldPos: Vector3d = ship.positionToWorld(shipPos)
Vec3 shipPos = ... Ship ship = ... Vec3 worldPos = ValkyrienSkies.positionToWorld(ship, shipPos);

Transformed a position represented by a JOML Vector3d

val shipPos: Vector3dc = ... val ship: Ship = ... val worldPos: Vector3d = ship.positionToWorld(shipPos, Vector3d())
Vector3dc shipPos = ... Ship ship = ... Vector3d worldPos = ValkyrienSkies.positionToWorld(ship, shipPos, new Vector3d());
Last modified: 03 June 2026