Skip to content

Class: world_state ​

World state describing whole world state in action planning.

Overrides operators: <, ==.

Source ​

C++ class world_state

Custom Constructor ​

world_state

Extends ​

Constructors ​

Constructor ​

ts
new world_state(): world_state;

Default constructor.

Returns ​

world_state

Overrides ​

EngineBinding.constructor

Constructor ​

ts
new world_state(another_state: world_state): world_state;

Copy constructor.

Parameters ​

ParameterTypeDescription
another_stateworld_stateTarget world state to copy.

Returns ​

world_state

Overrides ​

ts
EngineBinding.constructor

Methods ​

add_property() ​

ts
add_property(property: world_property): void;

Set property for world state.

Parameters ​

ParameterTypeDescription
propertyworld_propertyTarget property to add in world state.

Returns ​

void


clear() ​

ts
clear(): void;

Clear all properties in the state.

Returns ​

void


includes() ​

ts
includes(state: world_state): boolean;

Check if provided state is subset of current one.

Parameters ​

ParameterTypeDescription
stateworld_stateTarget state to check.

Returns ​

boolean

Whether current world state includes provided state.


property() ​

ts
property(id: number): world_property;

Get world property by id.

Parameters ​

ParameterTypeDescription
idnumberNumeric if of the required property.

Returns ​

world_property

Property id/state based on provided id.


remove_property() ​

ts
remove_property(id: number): void;

Remove world property from current world state.

Parameters ​

ParameterTypeDescription
idnumberIdentifier of the property to remove.

Returns ​

void

Properties ​

__name ​

ts
readonly __name: string;

LuaBind instance constructor name.

Inherited from ​

EngineBinding.__name


__name ​

ts
readonly static __name: string;

LuaBind class constructor name.

Inherited from ​

EngineBinding.__name