BBParam

Inherits:

Inherited By: BBAabb, BBArray, BBBasis, BBBool, BBByteArray, BBColor, BBColorArray, BBDictionary, BBFloat, BBFloat32Array, BBFloat64Array, BBInt, BBInt32Array, BBInt64Array, BBNode, BBPlane, BBProjection, BBQuaternion, BBRect2, BBRect2i, BBString, BBStringArray, BBStringName, BBTransform2D, BBTransform3D, BBVariant, BBVector2, BBVector2Array, BBVector2i, BBVector3, BBVector3Array, BBVector3i, BBVector4, BBVector4i

A base class for LimboAI typed parameters.

Description

A base class for LimboAI typed parameters, with the ability to reference a Blackboard variable or hold a raw value of a specific Variant.Type.

Note: Don’t instantiate. Use specific subtypes instead.

Properties

Variant

saved_value

null

ValueSource

value_source

0

StringName

variable

Methods

Variant.Type

get_type ( ) const

Variant

get_value ( Node scene_root, Blackboard blackboard, Variant default=null )


Enumerations

enum ValueSource:

ValueSource SAVED_VALUE = 0

The value is stored directly within the BBParam resource.

ValueSource BLACKBOARD_VAR = 1

The value is referenced by a variable name and retrieved from the Blackboard. The variable name is stored within the BBParam resource.


Property Descriptions

Variant saved_value = null

  • void set_saved_value ( Variant value )

  • Variant get_saved_value ( )

Stores the parameter value when value_source is set to SAVED_VALUE. The data type of the value is determined by get_type.


ValueSource value_source = 0

Specifies the source of the value for BBParam. See ValueSource.


StringName variable

  • void set_variable ( StringName value )

  • StringName get_variable ( )

Stores the name of a Blackboard variable when value_source is set to BLACKBOARD_VAR.


Method Descriptions

Variant.Type get_type ( ) const

Returns the expected data type of the parameter.


Variant get_value ( Node scene_root, Blackboard blackboard, Variant default=null )

Returns the value of the parameter.