Skip to main content

Module frame

Module frame 

Source
Expand description

Frame compositing: the baked background plus animated elements at time t. Particles snap to the cell grid (exact palette, small GIF diffs); sprites use integer nearest-neighbour scaling.

The activity, character and prop art come through SceneArt, so the same code plays live scenes (built-in art) and saved ones (their own copy).

Functions§

hero_time
The still-frame time used for stills, thumbnails and the static wallpaper: the first moment at or after the scene’s ember-based hero time (50 ms steps, up to 10 s) when the character shows the first frame of its activity’s start state, so a still never catches a blink or a mid-gesture. Independent of the Buddy toggle, so toggling it keeps the same moment.
hero_time_with_art
hero_time with the given art.
render_frame
Composites one frame at t_ms over a baked background (live clock).
render_frame_clocked
Like render_frame, with an explicit character clock: Clock::Loop makes the character follow the activity’s loop script for a seamless GIF.
render_frame_with_art
Composites one frame with the given art (built-in, or a saved scene’s).