Skip to content

Implement native GBA Follow Me targeting and round lifetime - #196

Closed
Roxas2712 wants to merge 22 commits into
UNDERdecoded:mainfrom
Roxas2712:codex/gen3-follow-me
Closed

Roxas2712 wants to merge 22 commits into
UNDERdecoded:mainfrom
Roxas2712:codex/gen3-follow-me

Conversation

@Roxas2712

@Roxas2712 Roxas2712 commented Oct 24, 2026 •

Copy link
Copy Markdown

Imported GBA Follow Me currently has no native effect producer, so a mod-selected attack ignores the center of attention. Register effect 172 and carry its side-local position through selected target resolution and the real turn queue.

The last successful caster wins on each side. A slot replacement inherits the position; a fainted holder stops drawing attacks while its timer still suppresses Lightning Rod. Live Follow Me wins over Lightning Rod. Self/spread target policies stay authoritative. State expires at next-turn planning, with ordinary status interruption, imported priority and owned PP.

Stacked on #195. Review the three feature commits after f84dfb5. The canonical effect adapter (#121) is an additional dependency only for public effect = "FOLLOW_ME" writes; the native feature does not require it.

Validation:

  • 180/180 focused checks: FireRed/Emerald, both sides/flanks, successive casters, explicit/default targets, fainting/replacement, Lightning Rod, self/spread/single policies, sleep refusal, Substitute/Protect, residual and next-turn lifetime, actual priority queues, PP and non-GBA guards.
  • Same API-3 consumer and fixture against unchanged read-only Gen1Recomp 535a5ec088c1ae1bf4d91dd3e35a56f64cf46d91: 24 isolated workers / 354 paired observations pass, including prior enemy-choice/argument/record/target contracts.
  • Negative control on unchanged Honor positional GBA mod-action targets through native execution #195: the new FireRed cases fail 29 assertions.
  • Full local quick run: 82/91 engine suites versus 80/90 on clean Honor positional GBA mod-action targets through native execution #195; SDK 3/3 and B30 pass. Exact FAIL-line Counters show no added failures and only the two old fingerprint failure lines removed. All 25 remaining lines across nine inherited suites match.
  • The intended new native registry entry changes the fixture fingerprint from 41e69caf4afa35ab to 128fc071ae7249cd. Removing only that entry and invalidating the cache restores the old value. The golden pins the intentional change.
  • Additional composed proof with Map portable move effects and secondary chances to native handlers #121: 14/14 checks load a real API-3 mod, patch/read the canonical effect, cast it, execute a mod-selected attack and verify actual redirection/PP.
  • actionlint and git diff --check pass.

The shared cases use synthetic extractor-shaped moves and actual native planning/execution, not a fresh cartridge import or full-playthrough proof. Remaining effect producers, automatic AI scoring, random-target/full RNG parity, link/called moves, damage amounts and item/switch/watch actions remain separate work. Gen1 is a read-only reference; no Gen1 change or publication is required. Hosted CI and combined-fork acceptance are reported separately.

Combined-fork acceptance: integrated into Roxas2712:codex/portability-testing, tested runtime 218cf2c. All 212/212 engine suites, 3/3 SDK suites and B30 pass with zero FAIL lines. The same 24-worker / 354-observation comparison passes on that clean runtime. The explicit canonical-effect mod proof passes 14/14. Integration updates the old missing-handler assertion and the audited effect-section fingerprint pin; all six other populated fingerprint sections remain identical. Subsequent combined-branch commits only record validation.

Hosted CI: all three workflows report action_required pending maintainer approval. The dedicated contract workflow has zero executed jobs. These are separate from local acceptance.

# Conflicts:
#	src/mods/Loader.lua
# Conflicts:
#	docs/modding.md
#	src/mods/Loader.lua
#	src/world/WorldAPI.lua
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant