Merge pull request #87928 from 31/dev/31/call-deferred-cs

Add `Callable` `call_deferred()` C# example
This commit is contained in:
Rémi Verschelde 2024-02-05 14:52:14 +01:00
commit 8631f68509
No known key found for this signature in database
GPG Key ID: C3336907360768E1
1 changed files with 10 additions and 2 deletions

View File

@ -98,10 +98,18 @@
<return type="void" />
<description>
Calls the method represented by this [Callable] in deferred mode, i.e. at the end of the current frame. Arguments can be passed and should match the method's signature.
[codeblock]
[codeblocks]
[gdscript]
func _ready():
grab_focus.call_deferred()
[/codeblock]
[/gdscript]
[csharp]
public override void _Ready()
{
Callable.From(GrabFocus).CallDeferred();
}
[/csharp]
[/codeblocks]
See also [method Object.call_deferred].
</description>
</method>