mirror of
https://github.com/bryanthaboi/gen1recomp
synced 2026-10-01 23:42:25 -04:00
6d841526b1
oak.facing was set and the battle pushed in the same synchronous callback, so the overworld never rendered a frame of Oak already turned toward the grass before the screen cut to battle. Traced home/overworld.asm: PalletTownOakGreetsPlayerScript (the turn) and PalletTownPikachuBattleScript (arming wCurOpponent) are separate script ticks, one main-loop iteration apart. OverworldLoopLessDelay burns two DelayFrame calls per iteration, calls RunMapScript (via JoypadOverworld) first, and only then checks wCurOpponent to jump into the battle -- so the turn from iteration A is on screen for the two DelayFrame calls that open iteration B, before that same iteration's RunMapScript arms wCurOpponent and falls straight into the battle check. hold(2, ...) restores exactly that beat.