Skip to content

[8/11] refactor(combat): one timing source – clip speeds from the boards - #224

Merged
arudaev merged 1 commit into
playtest/7-white-backdrop-v2from
playtest/8-clip-timing-v2
Oct 25, 2026
Merged

arudaev merged 1 commit into
playtest/7-white-backdrop-v2from
playtest/8-clip-timing-v2

Conversation

@arudaev

@arudaev arudaev commented Oct 25, 2026 •

Copy link
Copy Markdown
Member

Stack: 8 of 11 (playtest): base #223. Merge bottom-up, only on Alexander's word.

What and why

#156, criterion "one timing source": every clip's speed comes from its anims.json, with no n / 12 left in gameplay code. Before this PR, the chair's moves and the three enemies timed their frames by hand:

  • combat/clips.ts: frameTime, frameCount, clipTime and frameAt over a board's animation table. Without a table (tests, a board not loaded yet), the authored 12 fps and frame counts stay, so behaviour is unchanged today.
  • The chair (Sweeps, Overhead, LowSweep, Guard, GuardPush): each takes its board's table (chair-side, chair-overhead, chair-block). ChairCombat and the player pass the loaded ones. Retiming a clip is now an edit to its anims.json (or the board's fps in boards.json), not to five files.
  • Rover, crab, drone: same, with enemy-rover, enemy-crab and enemy-drone passed from rovers.ts.
  • Removed: lifePose and paintLife, unused, which carried their own * 12 and the generic setTintFill flash.

Left, on purpose:

  • the ladder's end times, which a test already pins to hero-ladder.anims.json;
  • the jump's landing fallback, used only before the atlases load (the player passes the real ones);
  • Jenny's ram sequence (jennyRam.ts), a scripted timeline. That one is next for Rework movement and combat feel against the art #156.

Issue

Refs #156 (the timing criterion; the stride, transitions, data-not-code and played-and-recorded criteria stay open)

Verification

  • npm test: 336 passed (every existing model test unchanged, run on the defaults); tsc clean.
  • In the browser (dev server): in the rust maze, all nine enemies (7 rovers, a crab, a drone) built with their loaded tables (clips set) animate on their own clocks (drive-02 → drive-04, walk-02 → walk-04, hover), with no errors.

Replaces #219: the same commits replayed on the current base, so the stack merges cleanly without a force-push (the old branch conflicted after fixes were carried up the stack).

@vercel

vercel Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
wincs Ready Ready Preview Oct 25, 2026 11:58am UTC

Request Review

@github-actions github-actions Bot added area:player Hero movement, animation state, camera area:combat Chair, guard, health, damage, save points, pickups area:enemies Autonomous robots and Jenny labels Oct 25, 2026
@arudaev arudaev changed the title [8/8] refactor(combat): one timing source – clip speeds from the boards [8/9] refactor(combat): one timing source – clip speeds from the boards Oct 25, 2026
@github-actions github-actions Bot added area:art Sprite sheets, stage plates, direction pack area:pipeline Rerunnable art and export scripts labels Oct 25, 2026
@arudaev
arudaev added this pull request to stack #230 October 25, 2026 10:14
@arudaev arudaev changed the title [8/9] refactor(combat): one timing source – clip speeds from the boards [8/10] refactor(combat): one timing source – clip speeds from the boards Oct 25, 2026
@arudaev
arudaev force-pushed the playtest/8-clip-timing-v2 branch from a1f174e to 64d63e8 Compare October 25, 2026 10:23
…ims.json

#156: the chair's moves (sweeps, overhead, low sweep, guard and its push)
and the rover, crab and drone timed their frames as n / 12. Each model now
takes its board's anims.json (combat/clips.ts: frameTime, frameCount,
clipTime, frameAt); the chair and the enemy row pass the loaded tables,
and without one the authored 12 fps stays. The unused lifePose /
paintLife (generic white tint) are gone.

Refs #156
@arudaev
arudaev force-pushed the playtest/8-clip-timing-v2 branch from 64d63e8 to f30aff8 Compare October 25, 2026 11:57
@arudaev
arudaev merged commit c862498 into main Oct 25, 2026
7 of 9 checks passed
@arudaev arudaev changed the title [8/10] refactor(combat): one timing source – clip speeds from the boards [8/11] refactor(combat): one timing source – clip speeds from the boards Oct 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:art Sprite sheets, stage plates, direction pack area:combat Chair, guard, health, damage, save points, pickups area:enemies Autonomous robots and Jenny area:pipeline Rerunnable art and export scripts area:player Hero movement, animation state, camera

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant