Inherits: VisualScriptNode < Resource < Reference < Object
A scripted Visual Script node.
A custom Visual Script node which can be scripted in powerful ways.
String | _get_caption ( ) virtual |
String | _get_category ( ) virtual |
int | _get_input_value_port_count ( ) virtual |
String | _get_input_value_port_name ( int idx ) virtual |
int | _get_input_value_port_type ( int idx ) virtual |
int | _get_output_sequence_port_count ( ) virtual |
String | _get_output_sequence_port_text ( int idx ) virtual |
int | _get_output_value_port_count ( ) virtual |
String | _get_output_value_port_name ( int idx ) virtual |
int | _get_output_value_port_type ( int idx ) virtual |
String | _get_text ( ) virtual |
int | _get_working_memory_size ( ) virtual |
bool | _has_input_sequence_port ( ) virtual |
Variant | _step ( Array inputs, Array outputs, int start_mode, Array working_mem ) virtual |
enum StartMode:
This is used by VisualScriptCondition to redirect the sequence to the "Done" port after the true
/false
branch has finished execution.
Using this requires you to have at least one working memory slot, which is used for the VisualScriptFunctionState.
Return the node's title.
Return the node's category.
Return the count of input value ports.
Return the specified input port's name.
Return the specified input port's type. See the Variant.Type values.
Return the amount of output sequence ports.
Return the specified sequence output's name.
Return the amount of output value ports.
Return the specified output's name.
Return the specified output's type. See the Variant.Type values.
Return the custom node's text, which is shown right next to the input sequence port (if there is none, on the place that is usually taken by it).
Return the size of the custom node's working memory. See _step for more details.
Return whether the custom node has an input sequence port.
Execute the custom node's logic, returning the index of the output sequence port to use or a String when there is an error.
The inputs
array contains the values of the input ports.
outputs
is an array whose indices should be set to the respective outputs.
The start_mode
is usually START_MODE_BEGIN_SEQUENCE, unless you have used the STEP_*
constants.
working_mem
is an array which can be used to persist information between runs of the custom node.
When returning, you can mask the returned value with one of the STEP_*
constants.
© 2014–2020 Juan Linietsky, Ariel Manzur, Godot Engine contributors
Licensed under the MIT License.
https://docs.godotengine.org/en/3.2/classes/class_visualscriptcustomnode.html