From 725ab3c55d605ce4432335532e3c5ef08fc96723 Mon Sep 17 00:00:00 2001 From: kayomn Date: Wed, 25 Jan 2023 23:55:18 +0000 Subject: [PATCH] Modify WorkerPrompt to use signals over awaitable functions --- map_editor.scn | 4 ++-- user_interface/worker_prompt.gd | 7 +++++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/map_editor.scn b/map_editor.scn index 1aa2188..eafb473 100644 --- a/map_editor.scn +++ b/map_editor.scn @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c9948b7c49555550b25347a7c9dd0a35752de1c06ab4f10cecbbd0be7d86aa67 -size 8462 +oid sha256:b1bd6e544f9f7711be7f8d59e72ab2f26e40b52ff7d939a999afbf0a6beca810 +size 8474 diff --git a/user_interface/worker_prompt.gd b/user_interface/worker_prompt.gd index 11c1f32..8b037dc 100644 --- a/user_interface/worker_prompt.gd +++ b/user_interface/worker_prompt.gd @@ -1,5 +1,10 @@ class_name WorkerPrompt extends Control +## +## +## +signal prompt_completed() + ## ## ## @@ -44,4 +49,6 @@ func prompt(display_message: String, steps: Array) -> void: await get_tree().process_frame _worker_thread.wait_to_finish() + prompt_completed.emit() hide() +