GridDirection
public enum GridDirection : CaseIterable, Equatable, Hashable, Comparable
Available movement directions on the grid.
-
Undocumented
Declaration
Swift
case north
-
Undocumented
Declaration
Swift
case east
-
Undocumented
Declaration
Swift
case south
-
Undocumented
Declaration
Swift
case west
-
Undocumented
Declaration
Swift
case northEast
-
Undocumented
Declaration
Swift
case southEast
-
Undocumented
Declaration
Swift
case southWest
-
Undocumented
Declaration
Swift
case northWest
-
true if
self
is a cardinal direction; false otherwise.Declaration
Swift
public var isCardinal: Bool { get }
-
true iff
self
is a diagonal direction; false otherwise.Declaration
Swift
public var isDiagonal: Bool { get }
-
A vector representing the direction of movement for a given direction.
Declaration
Swift
public var coordinateDelta: Point2 { get }
-
Returns the opposite direction of
rhs
.Declaration
Swift
public prefix static func - (rhs: `Self`) -> GridDirection
-
Declaration
Swift
public static func < (lhs: `Self`, rhs: `Self`) -> Bool