diff options
| author | Gene Pasquet <dev@etenil.net> | 2026-04-08 07:08:54 +0100 |
|---|---|---|
| committer | Gene Pasquet <dev@etenil.net> | 2026-04-08 07:08:54 +0100 |
| commit | afc30a12e25215ff5e9226c3b4f8fd127d9a4d68 (patch) | |
| tree | f736393fb8ebfd8982a4b79310a08c57ee430ff0 /docs/tweens.org | |
| parent | 9e8b75f9949259ef01942cd3717b79b044efddf7 (diff) | |
Move the engine-update to the scene
Diffstat (limited to 'docs/tweens.org')
| -rw-r--r-- | docs/tweens.org | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/docs/tweens.org b/docs/tweens.org index c278814..11bf510 100644 --- a/docs/tweens.org +++ b/docs/tweens.org @@ -63,17 +63,12 @@ Predicates on the tween struct. ** ~step-tweens~ (pipeline step) #+begin_src scheme -(step-tweens entity dt) +(step-tweens entity scene dt) #+end_src -Auto-advances ~#:tween~ on an entity. If the entity has no ~#:tween~ key, returns the entity unchanged. When the tween finishes (no more repeats), ~#:tween~ is removed from the entity. Respects ~#:skip-pipelines~: skipped when ~'tweens~ is in the list. +Auto-advances ~#:tween~ on an entity. If the entity has no ~#:tween~ key (guard fails), returns the entity unchanged. When the tween finishes (no more repeats), ~#:tween~ is removed from the entity. Respects ~#:skip-pipelines~: skipped when ~'tweens~ is in the list. -This is the recommended way to run tweens in most games. Attach a tween to an entity and include ~step-tweens~ in your per-entity pipeline: - -#+begin_src scheme -(scene-map-entities scene - (lambda (e) (step-tweens e dt))) -#+end_src +~step-tweens~ is part of ~default-engine-update~ and runs automatically each frame. No manual wiring is needed — just attach a ~#:tween~ to an entity and the engine handles the rest. ** Entity key: ~#:tween~ |
