Skip to content

Batch 57 · Player-owned ability state and work

2026-10-27. Starting HEAD 283f5ade; implementation ef1440f2, separate from this documentation checkpoint. R3 composition prerequisite and partial R4a ownership, not completed combat integration.

Change and dependency

Connecting dash through the old AbilityFunction would retain shared mutable Ability assets and global workers. Establish ownership first: PlayerAbilityRuntime clones definitions per player/run, preserves same-definition duplicate alias/reset and first-match admission, and owns explicitly submitted coroutine work. PlayerAbilityHost handles activation/suspension/disposal. PlayerActorRunParticipant prepares it while inactive when opted in; DevelopmentPlayerRun enables that option. Other factory modes and production scenes retain legacy ability ownership.

The temporary AbilityHolder list points at owned copies. Raw/foreign entries are rejected before execution. Base and selected character definitions are acquired before final stat projection; automatic character effects are not executed. Copies are retained across suspension, destroyed on disposal, and never saved back to authored definitions. Concrete character/perk counters, shields and effect bodies still require migration.

Nested IEnumerator work, replacement, cooldown display and cancellation share one scope. Run cancellation immediately retires sleeping work. Reentrant cancellation during iterator advancement/current access defers cleanup safely. Failure to clean one operation still allows other work, actor and assets to release, with the failure surfaced. This does not undo arbitrary gameplay mutations or own coroutines started elsewhere; migrated effects need their own cleanup. Re-enable does not resume stopped work or impose a new revive/pause policy.

AbilityCooldownCycle extracts the exact original admission/display rules for both legacy AbilityFunction and the new owner. It retains requested scaled waits, live cooldown read after the first wait, display stepping and float/overlap quirks. Legacy acquisition, admission and concrete worker code otherwise remain unchanged.

Lightweight evidence

Unity 6000.2.8f1, Linux64 headless. Original production iterator capture exits 0 in 32.794 seconds, recording 16 clock cases: cooldowns 0, 0.25, 1, 3 and 30 at modifiers 0.5, 1 and 2, plus a live cooldown change after the initial wait. The checked-in AbilityClockReference retains source identity and original observations, SHA256 18d29a2ad05eaaed6dd769924bae710275a46928f9ad478f14b8455ff34c61ce. New outputs compare against it; no original reference was repinned.

Final focused run exits 0 in 37.165 seconds. All 16 clock cases and 14 ownership groups pass: copy/definition identity, activation/admission, bypass, nested cleanup, scoped replacement, player isolation, reentrant advancement/current access, iterator-factory suspension, invalid legacy entries, disable/re-enable, context cancellation, cleanup failure and original-definition preservation.

Real shared-scene checks additionally verify two-player identity/state isolation, activation, release and cleanup failure without GameManager/GameSession/AbilityFunction bootstrap. All seven selected character definition/weapon handoffs pass, including Wu Ran, Tiamra and Zenova; their attacks are unexecuted. The existing development launcher retry/disposal regression passes, retaining player identity and releasing input ownership. Controlled delta and simulated-device focus settings belong to the fixture and are restored; they establish neither real-time performance nor physical-device acceptance.

Earlier excluded attempts exposed a too-short fixture wait, missing immediate cancellation in the new owner and headless input-focus setup. The cancellation defect was corrected; fixtures now await actual completion and use the existing isolated focus policy. Final review added the iterator Current reentrancy case. These are development/check iterations, not new confirmed defects in the shipped game. Existing CS8785 generator warnings remain; the accepted final run has no C# errors or exception headings.

Preservation and next work

All 7,809 original project files outside four intended edits match their captured bytes; ten source/reference/metadata paths are added. Scenes, prefabs, authored definitions, existing metadata/settings/build lists and earlier references remain unchanged. Reviewed generated Linux toolchain entries and attributed Unity/session preferences were archived and restored to original bytes; normal game data membership/hashes match. Unresolved audio deletions and generated Addressables Linux.meta remain excluded. Raw logs, disposable profiles and backups stay outside Git.

All 27 workstream follow-ups remain open. Continue R3 composition: inject character/pause/damage/dash effect services, consume the existing command frame once, connect dash through the ability owner and then enable owned simulation. Concrete skill workers must migrate before full combat activation. Player/AbilityHolder gameplay simulation remains disabled in the shared arena. No new native build, complete playthrough, physical-controller or Windows IL2CPP qualification was performed; batch 52 remains the latest native smoke. Main-menu freeze work, redesigned menus/rebinding/four-player layouts and other deferred features remain deferred.