diff options
Diffstat (limited to 'modules/visual_script/visual_script_expression.cpp')
-rw-r--r-- | modules/visual_script/visual_script_expression.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/modules/visual_script/visual_script_expression.cpp b/modules/visual_script/visual_script_expression.cpp index 5fc2ccf6e3..f673cbb06d 100644 --- a/modules/visual_script/visual_script_expression.cpp +++ b/modules/visual_script/visual_script_expression.cpp @@ -1506,6 +1506,19 @@ VisualScriptNodeInstance *VisualScriptExpression::instance(VisualScriptInstance return instance; } +void VisualScriptExpression::reset_state() { + if (nodes) { + memdelete(nodes); + nodes = nullptr; + root = nullptr; + } + + error_str = String(); + error_set = false; + str_ofs = 0; + inputs.clear(); +} + VisualScriptExpression::VisualScriptExpression() { } |