• Godot Help
  • Looking for a way to signal a funtion to be called on the next frame

a year later

I know this is a bit old, but since nobody mentioned this here... call_deferred does not wait until the next frame (as was stated to be the preference by the OP). Rather, it waits until "idle time", which can usually be thought of as the end of the current frame.

To actually wait until the next frame, you can use a zero-second timer, which in Godot 4.3 can be accomplished as follows:

# Do some stuff
await get_tree().create_timer(0).timeout
# Do some stuff on the next frame