Install Asset
Install via Godot
To maintain one source of truth, Godot Asset Library is just a mirror of the old asset library so you can download directly on Godot via the integrated asset library browser
Quick Information
Provides a GDScript helper class called "Signals" which exposes static functions for interacting with collections of signals, like Signals.all(), similar to Promise.all() in JavaScript.
GDScript Signals
A Godot 4.x plugin which provides a Signals
class which exposes static
functions for interacting with lists of Signals, like Promise.all()
in
JavaScript.
Usage
After importing and enabling the plugin, use one of the static methods attached
to Signals
detailed below.
all(signals_list)->Array
Given a list of Signals, waits until all of the signals complete, then returns an array of the results from the signals, matching the order the signals were passed in.
Example:
var results := await Signals.all([
weapon.target_was_hit,
weapon.animation_complete
])
any(signals_list)
Given a list of Signals, waits until at least one of those signals completes, returning the result of that completed signal.
Example:
var result = await Signals.any([
target.damage_taken,
bullet.expired
])
Contributing
Feel free to send pull requests or issues. This repository is a complete Godot 4.x project, so it can be imported locally for development.
Note: This repo comes with Gut unit tests, please make sure to add new test coverage and check existing tests when adding or changing code.
Provides a GDScript helper class called "Signals" which exposes static functions for interacting with collections of signals, like Signals.all(), similar to Promise.all() in JavaScript.
Reviews
Quick Information
Provides a GDScript helper class called "Signals" which exposes static functions for interacting with collections of signals, like Signals.all(), similar to Promise.all() in JavaScript.