Skip to content

Commit eab5aa6

Browse files
committed
Update documentation about execution order
1 parent bf8d5de commit eab5aa6

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

docs/execution_order.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,13 @@ Roughly sketched, the order looks like this:
66

77
1. `SceneTree.physics_frame`
88
- Rope update
9-
2. `_process()`
10-
3. `_physics_process()`
9+
2. `_physics_process()`
10+
3. `_draw()` (if `queue_redraw()` was called in `_physics_process()`)
11+
4. `_process()`
12+
5. `_draw()` (if `queue_redraw()` was called in `_process()`)
1113

12-
This assumes that the FPS match the physics tickrate, which is usually locked at 60 FPS.
13-
On a 144 Hz screen for example, it wouldn't match and you get more `_process()` frames than `_physics_process()` possibly making this lag even more noticable.
14+
This assumes that the FPS match the physics tick rate, which is usually locked at 60 FPS.
15+
On a 144 Hz screen for example, it wouldn't match, resulting in more `_process()` frames than `_physics_process()`.
1416

1517
`NativeRopeServer` provides a set of signals for fine-tuned execution order handling:
1618

@@ -27,11 +29,11 @@ They get emitted just before/after rope updates.
2729
3. Rope update
2830
4. `on_post_update`
2931
5. `on_post_post_update`
30-
2. `_process()`
31-
3. `_physics_process()`
32+
2. `_physics_process()`
33+
3. `_process()`
3234

3335
These signals are also used by various rope utilities like `RopeAnchor`, `RopeHandle` or `RopeRendererLine2D` to update the rope's properties or their own just before/after rope updates occur.
34-
At the moment they use the normal `pre` and `post` signals, not `pre_pre` or `post_post`.
36+
They use the normal `pre` and `post` signals, so it is safe to use `pre_pre` or `post_post` without interfering with them.
3537

3638
## Solving the One-Frame Delay
3739

0 commit comments

Comments
 (0)