[Core] Add way to check if a signal has any connections

Added to `Object` and `Signal`
This commit is contained in:
A Thousand Ships 2024-01-18 17:20:56 +01:00
parent 2be730a05b
commit 203d3be200
No known key found for this signature in database
GPG key ID: 2033189A662F8BD7
9 changed files with 49 additions and 0 deletions

View file

@ -4019,4 +4019,9 @@ bool Node::is_connected(const StringName &p_signal, const Callable &p_callable)
return Object::is_connected(p_signal, p_callable);
}
bool Node::has_connections(const StringName &p_signal) const {
ERR_THREAD_GUARD_V(false);
return Object::has_connections(p_signal);
}
#endif