mirror of
https://github.com/godotengine/godot.git
synced 2024-11-10 14:12:51 +00:00
Improve call_group documentation
(cherry picked from commit 31ef94f2ec
)
This commit is contained in:
parent
7c9e0595b7
commit
5b97007def
@ -18,7 +18,7 @@
|
||||
<argument index="0" name="group" type="String" />
|
||||
<argument index="1" name="method" type="String" />
|
||||
<description>
|
||||
Calls [code]method[/code] on each member of the given group. You can pass arguments to [code]method[/code] by specifying them at the end of the method call.
|
||||
Calls [code]method[/code] on each member of the given group. You can pass arguments to [code]method[/code] by specifying them at the end of the method call. This method is equivalent of calling [method call_group_flags] with [constant GROUP_CALL_DEFAULT] flag.
|
||||
[b]Note:[/b] [code]method[/code] may only have 5 arguments at most (7 arguments passed to this method in total).
|
||||
[b]Note:[/b] [method call_group] will always call methods with an one-frame delay, in a way similar to [method Object.call_deferred]. To call methods immediately, use [method call_group_flags] with the [constant GROUP_CALL_REALTIME] flag.
|
||||
</description>
|
||||
@ -31,7 +31,9 @@
|
||||
<description>
|
||||
Calls [code]method[/code] on each member of the given group, respecting the given [enum GroupCallFlags]. You can pass arguments to [code]method[/code] by specifying them at the end of the method call.
|
||||
[b]Note:[/b] [code]method[/code] may only have 5 arguments at most (8 arguments passed to this method in total).
|
||||
[b]Note:[/b] Group call flags are used to control the method calling behavior. If the [constant GROUP_CALL_REALTIME] flag is present in the [code]flags[/code] argument, methods will be called immediately. If this flag isn't present in [code]flags[/code], methods will be called with a one-frame delay in a way similar to [method call_group].
|
||||
[codeblock]
|
||||
get_tree().call_group_flags(SceneTree.GROUP_CALL_REALTIME | SceneTree.GROUP_CALL_REVERSE, "bases", "destroy") # Call the method immediately and in reverse order.
|
||||
[/codeblock]
|
||||
</description>
|
||||
</method>
|
||||
<method name="change_scene">
|
||||
|
Loading…
Reference in New Issue
Block a user