From afc30a12e25215ff5e9226c3b4f8fd127d9a4d68 Mon Sep 17 00:00:00 2001 From: Gene Pasquet Date: Wed, 8 Apr 2026 07:08:54 +0100 Subject: Move the engine-update to the scene --- docs/tweens.org | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'docs/tweens.org') 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~ -- cgit v1.2.3