docs: row 67, the Pewter Gym trainer lost on repeat (12.31, audit)

This commit is contained in:
acamilo 2026-09-29 15:34:01 +00:00
parent 7f56feac46
commit df08d2eb51
2 changed files with 107 additions and 0 deletions

View file

@ -1913,6 +1913,45 @@ a door is taken the way the cartridge takes it, and the map graph says what the
decoder, the reward catalog, the adapter version, the roles and the compatibility string are decoder, the reward catalog, the adapter version, the roles and the compatibility string are
untouched. untouched.
### 12.31 A battle lost on repeat is the readout's choice when the pad offers the move that wins (2026-09-29, row 67)
Live on v0.6.5, rung 10, an hour and a half in the Pewter Gym (map 54): per 3,000 events `NEXT`
1,332, `MOVE 2` 83, `MOVE 3` 13, `MOVE 1` 0, `GO OBJECTIVE` 30, `NO` 17, no battle won. The feed
read `battle` most of the time, but the fly was not in one battle. It was in a ring. It lost
29 battles in a row to the gym's Jr. Trainer (Diglett L11, Sandshrew L11), whited out to Pewter
(`wLastBlackoutMap` `$02`, money 0) and walked straight back in. Reproduced from the live
checkpoint (`FLY_ROW67_CHECKPOINT`).
- **The pad was right.** Squirtle L11 has TACKLE 35/35, TAIL WHIP 30/30 and BUBBLE 30/30, and
the trainer's Pokémon are Ground type. In a trainer battle with a party of one and no Potion,
the menu's pad is `MOVE 1`, `MOVE 2`, `MOVE 3`, which is every move with PP and an effect.
RUN, ITEM, SWITCH and THROW BALL each have nothing behind them there. Every turn advances.
In 932 own-turn frames, no move with PP and an effect was missing from the pad.
- **The choice was the readout's.** Per live battle, TAIL WHIP was 155 of 178 moves and BUBBLE
23. TAIL WHIP has an effect until the stage reaches -6, and 12.23 withholds it from there. Squirtle
faints at about the sixth turn, so the rule arrives as the battle ends (live: `22222233`).
A readout with no favourite wins with the same pad: uniform over it, the trainer is beaten on
all three seeds, and on the committed seed in the third battle. The live readout's favourite,
replayed, loses 17 of 17 battles.
- **PP never runs out.** Each loss spends about six TAIL WHIPs of 30, and the whiteout heals the party and
restores PP. The out-of-PP path is sound anyway: from the no-PP checkpoint, a trainer battle
with a party of one and every move at 0, the pad is `MOVE 1` alone (FIGHT's backstop, 12.8),
and "has no moves left!" and Struggle end the battle in 1,487 frames.
- **Nothing in the macros changes.** Moving the fly off TAIL WHIP would be ranking a move. The
one pad rule measured that would work, withholding a stat-lowering move once the target's
stage has moved, wins the first battle on both seeds (two stages: the second). It is a rule
about which move is good rather than one about what the cartridge refuses, so it waits for
the operator, like the reward options (`infra/docs/macros-traps.md` row 67).
- **What ships is detection.** The watchdog's check 10 gains `unwon-battles`: 24 or more `MOVE
n` decisions and no battle-won reward (`wildwin`, `trainer`, `badge`) in the ten-brain-minute
window, on two probes, with no new ground. Replayed on the live log, it flags from 14:01. The
existing rules first flag at 14:46, because a stray tile reward on a walk back reset
`unrewarded`. The recovery ladder acts on the flag as on any other, and a restart alone
does not change the readout.
Nothing is ranked, weighted or pressed for the fly. The decoder, the reward catalog, the adapter
version, the roles and the compatibility string are untouched.
## 13. Shops and Pokémon Centers (the operator, 2026-09-17: "refactor the shop macros. make it a ## 13. Shops and Pokémon Centers (the operator, 2026-09-17: "refactor the shop macros. make it a
## priority to visit the shop at least once per area; make shop macros item purchases. same ## priority to visit the shop at least once per area; make shop macros item purchases. same
## for the Pokécenter. heal should be a macro.") ## for the Pokécenter. heal should be a macro.")

View file

@ -3370,3 +3370,71 @@ gives these results:
- **65b to 65d**: out, but seed 3 then stands outside the front door with an empty pad for the rest - **65b to 65d**: out, but seed 3 then stands outside the front door with an empty pad for the rest
of the window (65e). of the window (65e).
- **branch**: all six leave with no empty pad, and three win the Cascade Badge. - **branch**: all six leave with no empty pad, and three win the Cascade Badge.
## 2026-09-29, row 67: the Pewter Gym trainer, lost on repeat
### What was live
v0.6.5, macros mode, reset to rung 8 at 12:16Z and back at PEWTER CITY by 13:40. The fly
entered the Pewter Gym (map 54) at 13:41, talked to the guide (#3) and to the Jr. Trainer
(#2). For the next hour and a half the pad read `battle` most of the time.
Per 3,000 events: `NEXT` 1,332, `MOVE 2` 83, `MOVE 3` 13, `MOVE 1` 0, `GO OBJECTIVE` 30, `NO` 17,
`GO FRONTIER` 13, `TALK` 7. There was no battle-won reward, only two tile rewards on map 54. Check
10 stayed clear.
### Reproduction (the pulled checkpoint, hot generation 230739)
- The checkpoint is on the walk back, not in a battle: Pewter City (18, 13), `wIsInBattle` 0,
`wLastBlackoutMap` `$02`, money 0, no badge, `EVENT_BEAT_PEWTER_GYM_TRAINER_0` clear. The party
is one Squirtle L11, 34/34: TACKLE 35/35, TAIL WHIP 30/30, BUBBLE 30/30.
- The opponent is `wTrainerClass` `$05` (Jr. Trainer♂) #1, `wEnemyPartyCount` 2: Diglett L11 and
Sandshrew L11, both Ground (`wEnemyMonType1` `$04`).
- Driven with the real palette and the live readout's measured favourite (TAIL WHIP 87%, else
BUBBLE), the cycle is the live one. `GO OBJECTIVE` into the gym, then `TALK` and the guide's
YES/NO. Then the trainer's challenge starts the battle. The own-turn pad is `MOVE 1, MOVE 2, MOVE 3`
on every turn, and each turn resolves in about 530 frames. Squirtle falls 34 → 29 → 24 → 19
→ 11 → 6 → 0 while Diglett's DEFENSE falls to -6. Then `wIsInBattle` `$ff`, `wBattleResult` 1,
the whiteout to Pewter (13, 26) with PP back to 30, and the walk back. One battle takes about
4,500 frames.
- Live, per battle (29 battles, from the event log): TAIL WHIP 155, BUBBLE 23, TACKLE 0, and 5 to 8
moves each. Where TAIL WHIP ran out of effect before the faint, 12.23 withheld it and the fly
pressed BUBBLE (`22222233`).
| # | trap | trigger | test | fix, or why it is left |
| --- | --- | --- | --- | --- |
| 67 | a readout that favours TAIL WHIP loses every battle against a trainer it could beat; the whiteout heals the party, so PP never runs out and the ring never ends | the Pewter Gym's Jr. Trainer, Squirtle alone | `row67_the_gym_trainer_is_beaten_from_what_the_pad_deals` | **left, the fly's**: the pad offers every move with PP and an effect on every own-turn frame (0 missing in 932) and a uniform choice wins. Options for the operator below |
| 67b | check 10 did not flag: a stray tile reward (a new gym tile on a walk back) every ~20 minutes reset `unrewarded`, and battles are not a sequence of four names | a whiteout ring with a walk in it | `lint.sh` check 10 case 8 | **fixed**: `unwon-battles` (24+ `MOVE n`, no `wildwin`/`trainer`/`badge` reward, two probes, no new ground) |
| 67c | the no-PP ROM test asserted "more than one button" on a trainer battle whose only honest button is `MOVE 1` (12.8's backstop); it was red on main and skipped without `FLY_NOPP_CHECKPOINT` | the no-PP checkpoint | `macros_mode_ends_a_turn_with_no_move_left_on_the_cartridge` | **fixed (test)**: at least one button, and the battle ends (Struggle, 1,487 frames) |
### The options, measured
From the live checkpoint, 60,000 frames per arm (16.7 brain minutes), real palette. The driver
is harness choice, not the fly's:
| arm | trainer battles (L lost, W won) | trainer beaten | Brock beaten |
| --- | --- | --- | --- |
| live favourite (TAIL WHIP 87%), seed 1 | LLLLLLLLL | no | no |
| live favourite, seed 2 | LLLLLLLL | no | no |
| uniform over the pad, seeds 1 / 2 / 3 | LLW / LLLLW / LLLW | f32,940 / f46,293 / f41,030 | seed 1 |
| BUBBLE whenever dealt | W | f12,234 | yes |
| TACKLE whenever dealt | LLLLLW | f59,253 | no |
| live favourite, stat-down move withheld once the target's stage is -1 or lower, seeds 1 / 2 | W / W | f9,165 / f9,304 | yes / yes |
| the same at -2, seeds 1 / 2 | LW / LW | f17,053 / f19,033 | yes / yes |
| the same at -3, seed 1 | LLLLLW | f54,551 | no |
- **Withhold a move with no effect on this target** (12.23's rule): it already applies, and TAIL
WHIP has an effect until -6. The fly faints at about that turn, so the rule changes nothing here.
- **Withhold a stat-lowering move once it has done something**: the -1 arm wins the first battle
on both seeds and then beats Brock. It is a pad rule about which move is good, not about what
the cartridge refuses, so it is a doctrine change for the operator. It would also hide GROWL,
SAND-ATTACK and similar moves after one use in every battle.
- **Reward damage dealt**: this is a reward-catalog change, out of scope for loop review, and it
cannot be measured without the brain. Nothing in the current catalog separates BUBBLE from
TAIL WHIP until a battle is won, and none is.
- **Watchdog detection plus the recovery ladder**: shipped (67b). Replayed probe by probe on the
live log with uniqueLocations proxied from the tile rewards, base check 10 first flags at 14:46
(`unrewarded`). The branch flags `unwon-battles` at 14:01, 14:16, 14:21, 14:36 and 14:41; a
tile reward at 14:06 and 14:26 clears one probe each. The healthy windows before the gym
(13 to 46 `MOVE n`, 1 to 4 wins each) are not flagged. The ladder's restart does not change the
readout, and a reset to PEWTER CITY replays the same gym. Only the reset to the rung below adds
forest battles, and whether that is enough was not measured.