Animation Frames — video-first
The image generator draws poses; the VIDEO generator understands motion —
leg alternation, arc continuity, cloth and fire dynamics come free because
video must animate them. So don't ask the image model to imagine
mid-motion poses: animate the base and harvest real frames.
App-builder execution (read first)
This skill is doctrine (motion laws, loop QC, when to use video). In the
app-builder sandbox, do not run a freeform ffmpeg harvest or invent a
random keyable #hex background.
| Step |
Do this |
| Production sprites / fixed grids |
generate2dsprite — solid #FF00FF magenta sheets + chroma scripts |
| Denser locomotion from video |
video2dsprite — base still on #FF00FF → image_to_video → skill scripts (ffmpeg + chroma) |
| Keyable background |
Always #FF00FF when using either pipeline (required for chroma) |
| This skill |
Loop / flip-test / motion laws below — apply after the pipeline runs |
Open .grok/skills/video2dsprite/SKILL.md or .grok/skills/generate2dsprite/SKILL.md
and follow their workflows for generation and postprocess. Then apply the
laws and flip test here before shipping frames into the game.
Default pipeline (intent)
- Base frame. Subject in neutral/starting pose, full style words, side /
game-appropriate view, solid
#FF00FF background (app-builder chroma
key). game-asset-core defaults apply.
- Animate.
image_to_video from the base: one clear motion, in place,
static camera ("the knight walks in place, side view, camera locked",
6s). Keep the shot simple — one subject, one motion. Prefer running this
through video2dsprite so harvest + chroma are consistent.
- Harvest + clean. Use
video2dsprite scripts (not ad-hoc
ffmpeg -i … fps=12 alone). Magenta flood-fill / despill lives there;
do not re-key with a different flat #hex unless you leave the magenta
pipeline entirely.
- Select. Pick frames that (a) capture the motion's distinct phases and
(b) LOOP — the sequence's end must flow back into its start. Don't force
a count: if the motion reads best with 8, 10, or 12 frames, deliver that
many (more frames = smoother in-engine). For a cycle, select one full
period using motion landmarks (foot contacts, wing extremes, flame peaks).
- Package. Deliver frames in play order (zero-padded names) and/or a
sheet per game-asset-core rules (uniform cells, no dividers) — or the
transparent strips/grids emitted by
video2dsprite /
generate2dsprite. State the intended fps.
Fall back to keyframe-by-keyframe image_edit (still on #FF00FF when
postprocessing with the sprite scripts) only when video fails the motion
(rare: very stylized poses, single dramatic keyframes) — and then plan
phases yourself and obey the laws below. Prefer generate2dsprite for
crisp production multi-frame grids.
Motion laws (verify against these, whatever the pipeline)
- Cycles loop; alternating gaits spend half the period mirrored.
- Continuity: limbs, props, anatomy, effects move on continuous paths —
nothing teleports, vanishes, or duplicates between adjacent frames.
- Physics reads in stills: airborne shows air, anticipation compresses,
follow-through overshoots; effects stay anchored to their origin unless
the request moves them.
- Energy matches the ask: idle/subtle means barely-different frames.
Verify — the flip test
View the final frames strictly in order and narrate the motion; check
loop closure explicitly (last→first). A hedge in your narration is a
failed frame. The video pipeline usually passes this on the first try —
that's why it's the default.
1---2name: game-animation-frames3description: Deep guide for game ANIMATION assets: motion cycles, action keyframes, effect sequences, and animation sprite sheets — built around a video-first pipeline. In this app-builder sandbox, execute via the video2dsprite / generate2dsprite skills (magenta + scripts), not ad-hoc ffmpeg. Use whenever generating anything that moves: walk/run cycles, attacks, idles, FX, flags, fire, animation sheets. Complements game-asset-core.4---56# Animation Frames — video-first78The image generator draws poses; the VIDEO generator understands motion —9leg alternation, arc continuity, cloth and fire dynamics come free because10video must animate them. So don't ask the image model to imagine11mid-motion poses: animate the base and harvest real frames.1213## App-builder execution (read first)1415This skill is **doctrine** (motion laws, loop QC, when to use video). In the16app-builder sandbox, **do not** run a freeform `ffmpeg` harvest or invent a17random keyable `#hex` background.1819| Step | Do this |20| --- | --- |21| Production sprites / fixed grids | **`generate2dsprite`** — solid **`#FF00FF`** magenta sheets + chroma scripts |22| Denser locomotion from video | **`video2dsprite`** — base still on **`#FF00FF`** → `image_to_video` → skill scripts (ffmpeg + chroma) |23| Keyable background | Always **`#FF00FF`** when using either pipeline (required for chroma) |24| This skill | Loop / flip-test / motion laws below — apply after the pipeline runs |2526Open `.grok/skills/video2dsprite/SKILL.md` or `.grok/skills/generate2dsprite/SKILL.md`27and follow their workflows for generation and postprocess. Then apply the28laws and flip test here before shipping frames into the game.2930## Default pipeline (intent)31321. **Base frame.** Subject in neutral/starting pose, full style words, side /33 game-appropriate view, **solid `#FF00FF` background** (app-builder chroma34 key). game-asset-core defaults apply.352. **Animate.** `image_to_video` from the base: one clear motion, in place,36 static camera ("the knight walks in place, side view, camera locked",37 6s). Keep the shot simple — one subject, one motion. Prefer running this38 through **`video2dsprite`** so harvest + chroma are consistent.393. **Harvest + clean.** Use **`video2dsprite`** scripts (not ad-hoc40 `ffmpeg -i … fps=12` alone). Magenta flood-fill / despill lives there;41 do not re-key with a different flat `#hex` unless you leave the magenta42 pipeline entirely.434. **Select.** Pick frames that (a) capture the motion's distinct phases and44 (b) LOOP — the sequence's end must flow back into its start. Don't force45 a count: if the motion reads best with 8, 10, or 12 frames, deliver that46 many (more frames = smoother in-engine). For a cycle, select one full47 period using motion landmarks (foot contacts, wing extremes, flame peaks).485. **Package.** Deliver frames in play order (zero-padded names) and/or a49 sheet per game-asset-core rules (uniform cells, no dividers) — or the50 transparent strips/grids emitted by **`video2dsprite`** /51 **`generate2dsprite`**. State the intended fps.5253Fall back to keyframe-by-keyframe `image_edit` (still on `#FF00FF` when54postprocessing with the sprite scripts) only when video fails the motion55(rare: very stylized poses, single dramatic keyframes) — and then plan56phases yourself and obey the laws below. Prefer **`generate2dsprite`** for57crisp production multi-frame grids.5859## Motion laws (verify against these, whatever the pipeline)6061- Cycles loop; alternating gaits spend half the period mirrored.62- Continuity: limbs, props, anatomy, effects move on continuous paths —63 nothing teleports, vanishes, or duplicates between adjacent frames.64- Physics reads in stills: airborne shows air, anticipation compresses,65 follow-through overshoots; effects stay anchored to their origin unless66 the request moves them.67- Energy matches the ask: idle/subtle means barely-different frames.6869## Verify — the flip test7071View the final frames strictly in order and narrate the motion; check72loop closure explicitly (last→first). A hedge in your narration is a73failed frame. The video pipeline usually passes this on the first try —74that's why it's the default.