UnigineScript
The Language
Core Library
Engine Library
Node-Related Classes
GUI-Related Classes
Plugins Library
High-Level Systems
Samples
Usage Examples
C++ API
API Reference
Integration Samples
Usage Examples
C++ Plugins
Migration
Migrating to UNIGINE 2.0
C++ API Migration
Migrating from UNIGINE 2.0 to UNIGINE 2.1

Unigine::NodeTrigger Class

Interface for node trigger handling. See also the UnigineScript analog.

To use this class, include the UnigineNodeTrigger.h file.

Unigine::NodeTrigger Class

Members


static int type ()

NodeTrigger type.

Return value

NodeTrigger type identifier.

static Ptr< NodeTrigger > create (const NodePtr & node)

NodeTrigger constructor.

Arguments

  • const NodePtr & node - Node smart pointer.

static Ptr< NodeTrigger > create ()

NodeTrigger constructor.

virtual void setEnabledCallbackName (const char * name) const =0

Sets a callback function to be fired when the trigger node is enabled. This function should take a NodeTrigger, which fires the callback, as the first argument.

Arguments

  • const char * name - World script function name.

virtual const char * getEnabledCallbackName () const =0

Returns the name of callback function to be fired on enabling the trigger node. This function is set by using the setEnabledCallbackName() function.

Return value

World script function name.

virtual void setPositionCallbackName (const char * name) const =0

Sets a callback function to be fired when the trigger node position has been changed. This function should take a NodeTrigger, which fires the callback, as the first argument.

Arguments

  • const char * name - World script function name.

virtual const char * getPositionCallbackName () const =0

Returns the name of callback function to be fired on changing the trigger node position. This function is set by using the setPositionCallbackName() function.

Return value

World script function name.

virtual void setEnabledCallback (CallbackBase * func) const =0

Sets a pointer to a callback to be fired when the trigger node is enabled.

Arguments

  • CallbackBase * func - Callback pointer. The callback arguments must be (NodeTriggerPtr,...).

virtual void setPositionCallback (CallbackBase * func) const =0

Sets a pointer to a callback to be fired when the trigger node has been changed.

Arguments

  • CallbackBase * func - Callback pointer. The callback arguments must be (NodeTriggerPtr,...).
Last update: 2017-07-03