Coordinates class

Unified representation of cube and axial coordinates systems.

Constructors

Coordinates.axial(int q, int r)
Axial constructor
Coordinates.cube(int x, int y, int z)
Cube constructor
const

Properties

hashCode int
The hash code for this object.
no setteroverride
q int
no setter
r int
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
x int
final
y int
final
z int
final

Methods

distance(Coordinates other) int
Distance measured in steps between tiles. A single step is only going over edge of neighbouring tiles.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
override

Operators

operator +(Coordinates other) Coordinates
operator -(Coordinates other) Coordinates
operator ==(Object other) bool
The equality operator.
override

Constants

zero → const Coordinates
Constant value of space center