x component of the current coordinate.
z component of the current coordinates.
returns a version of this Coord as a Fine-space Coordinate.
returns the four corners of this Coord as Fine-space Coordinates.
local coord = osrs.ClientOp.coord()
local topRight, topLeft, bottomRight, bottomLeft = coord:getFineCoordinateCorners()
osrs.printf("Top Right - X: %d, y: %d, z: %d", topRight.x, topRight.y, topRight.z)
osrs.printf("Top Left - X: %d, y: %d, z: %d", topLeft.x, topLeft.y, topLeft.z)
osrs.printf("Bottom Right - X: %d, y: %d, z: %d", bottomRight.x, bottomRight.y, bottomRight.z)
osrs.printf("Bottom Left - X: %d, y: %d, z: %d", bottomLeft.x, bottomLeft.y, bottomLeft.z)
returns a tile coordinate in the format of [level], [MapSquareX], [MapSquareZ], [TileX], [TileZ]
-- Create new coord
local coord = osrs.MapCoord.new(1, 10, 10)
-- Get the map tile information of the coord
local level, mapX, mapZ, tileX, tileZ = coord:getMapTile()
-- Print all of the tile map info
osrs.print(tostring(level))
osrs.print(tostring(mapX))
osrs.print(tostring(mapZ))
osrs.print(tostring(tileX))
osrs.print(tostring(tileZ))
Returns a new coordinate that is offset by the provided translation amount.
the amount to move in the y-direction
the amount to move in the x-direction
the amount to move in the z-direction
returns the coordinate of the player expressed as a single number, for use in legacy functions such as ClientOp.highlightTileOn.
StaticnewCreates a new Coord with the given map tile coordinates.
level value of the coordinates.
first value of the tile x-coordinate.
first value of the tile z-coordinate.
second value of the tile x-coordinate.
second value of the tile z-coordinate.
level component of the current coordinate.