SetDeferred

在下一帧时设置属性

CS
@GodotObject.SetDeferred("属性名称", Value);

在Area的OnBodyEntered函数中设置monitoring需要SetDeferred

CallDeferred

在下一帧执行指定函数

CS
@GodotObject.CallDeferred("函数名称", params Variant[] args);

原地等待一帧

CS
await ToSignal(GetTree(), SceneTree.SignalName.ProcessFrame);

: Cheyne Xie

: https://chaim.eu.org/posts/2e74d08d/

: CC BY-NC-SA 4.0

This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. Please attribute the source, use non-commercially, and maintain the same license.