Path

abstract class Path : Validatable

Path

Constructors

Path
Link copied to clipboard
fun Path()

Types

Companion
Link copied to clipboard
object Companion
TraversalOption
Link copied to clipboard
enum TraversalOption : Enum<Path.TraversalOption>

Defines the path traversal options.

Functions

end
Link copied to clipboard
abstract fun end(): Tile?

Gets the end tile of this path.

next
Link copied to clipboard
abstract operator fun next(): Tile?

Gets the next immediately available vertex in this path.

start
Link copied to clipboard
abstract fun start(): Tile?

Gets the start tile of this path.

traverse
Link copied to clipboard
fun traverse(): Boolean

Takes a step along this path if appropriate. Specifies only TraversalOption.SPACE_ACTIONS.

abstract fun traverse(options: EnumSet<Path.TraversalOption>): Boolean

Takes a step along this path if appropriate. If the path cannot be traversed due to the player being too far from its vertices or already at the end vertex, false will be returned. In all other cases, true will be returned, but an action will not necessarily be performed (based on the given options).

valid
Link copied to clipboard
abstract fun valid(): Boolean

Inheritors

OldLocalPath
Link copied to clipboard
TilePath
Link copied to clipboard