Rakugo-Dialogue-System
Rakugo-Dialogue-System copied to clipboard
Emergency stop script execute
We cannot kill thread in Godot. Only way it is quit them properly.
Call Rakugo.execute_script(script_name)
or Rakugo.parse_and_execute(file_name)
, start a thread to read and execute RakuScript.
Currently we should finish all script reading to finish execution. We cannot interrupt it in the middle.
I propose to add a method to Rakugo, like "Rakugo.emergency_stop_script(script_name)`, to interrupt execution in case it need.
Of course, signal "on_execute_script_finished" is send, in all cases.
This is a good idea