Skip to content

Instantly share code, notes, and snippets.

@ParadoxV5
Created October 21, 2025 20:13
Show Gist options
  • Save ParadoxV5/d936d32eaef196f13e106aa99a66865d to your computer and use it in GitHub Desktop.
Save ParadoxV5/d936d32eaef196f13e106aa99a66865d to your computer and use it in GitHub Desktop.
await await await await
extends Timer
func await_await() -> Signal:
print("await signal")
await timeout
print("await return")
return timeout
func _enter_tree() -> void:
print("await start")
## method call → signal
await await await_await()
print("await done")
[gd_scene load_steps=2 format=3]
[ext_resource type="Script" path="res://await_await.gd" id="await_await"]
[node name="Await Await" type="Timer"]
autostart = true
script = ExtResource("await_await")
@ParadoxV5
Copy link
Author

ParadoxV5 commented Oct 21, 2025

I prefer the Observer patternSignal#connecting Callables.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment