ConditionWorldState

data class ConditionWorldState(val state: ConditionState = emptyMap()) : WorldState

Represents the state of the world at any time. World state is just a map. This class exposes operations on the state.

Constructors

Link copied to clipboard
constructor(state: ConditionState = emptyMap())

Properties

Link copied to clipboard
Link copied to clipboard
open val timestamp: Instant

Functions

Link copied to clipboard
open fun infoString(verbose: Boolean?, indent: Int): String
Link copied to clipboard
operator fun plus(pair: <Error class: unknown class><String, ConditionDetermination>): ConditionWorldState
Link copied to clipboard
infix fun satisfiesPreconditions(preconditions: EffectSpec): Boolean

Are all preconditions satisfied in this world state?

Link copied to clipboard
Link copied to clipboard

Generate all possible changes to the world state where only one condition is changed For each existing condition, generate variants where that condition is flipped to the other values (TRUE -> FALSE and UNKNOWN, FALSE -> TRUE and UNKNOWN, UNKNOWN -> TRUE and FALSE)