From cc1a0e7cc5053fba7c22c41ccc02c2c193dd67bd Mon Sep 17 00:00:00 2001 From: robjlyons <81177492+robjlyons@users.noreply.github.com> Date: Wed, 18 Feb 2026 23:23:55 +0000 Subject: [PATCH] Revert unstable species ownership catch gating --- engine/battle/core.asm | 15 +++++---------- engine/events/poison.asm | 32 +++----------------------------- 2 files changed, 8 insertions(+), 39 deletions(-) diff --git a/engine/battle/core.asm b/engine/battle/core.asm index f13ed4b7..9f45c390 100644 --- a/engine/battle/core.asm +++ b/engine/battle/core.asm @@ -1194,18 +1194,13 @@ EnsureEncounterCatchFlagsInitialized: ret EnableEncounterCatchSRAM_Battle: - ld a, $0A - ld [$0000], a ; enable SRAM - ld a, $01 - ld [$6000], a ; MBC1: RAM banking mode (harmless on others) - ld a, BANK(sMapEncounterCatchFlags) - ld [$4000], a ; select SRAM bank that holds the flags - ret + ld a, BANK(sMapEncounterCatchFlags) + call OpenSRAM + ret DisableEncounterCatchSRAM_Battle: - xor a - ld [$0000], a ; disable SRAM - ret + call CloseSRAM + ret ; asks if you want to use next mon ; stores whether you ran in C flag diff --git a/engine/events/poison.asm b/engine/events/poison.asm index 9d87b3ca..f3c66345 100644 --- a/engine/events/poison.asm +++ b/engine/events/poison.asm @@ -68,7 +68,9 @@ ApplyOutOfBattlePoisonDamage: callfar PlayPikachuSoundClip callfar_ModifyPikachuHappiness PIKAHAPPY_PSNFNT .curMonNotPlayerPikachu - call HandlePoisonFaintedMonRanAway + ld a, [wWhichPokemon] + ld [wPlayerMonNumber], a + callfar HandleFaintedPlayerMonRanAway pop de pop hl jr .restartAfterRemoval @@ -148,34 +150,6 @@ ApplyOutOfBattlePoisonDamage: ld [wOutOfBattleBlackout], a ret -PoisonFaintedMonRanAwayText: - text_far _PokemonRanAwayBadTrainingText - text_end - -HandlePoisonFaintedMonRanAway: - ld a, [wPartyCount] - cp 1 - ret z ; don't remove the final party mon to avoid invalid 0-mon party state - ld hl, wPartyMonNicks - call GetPartyMonName - ld hl, PoisonFaintedMonRanAwayText - call PrintText - xor a - ld [wRemoveMonFromBox], a - call RemovePokemon - ld a, [wPartyCount] - and a - ret z - dec a - ld b, a - ld a, [wWhichPokemon] - cp b - jr c, .done - ld a, b - ld [wWhichPokemon], a -.done - ret - Func_c4c7: ld a, [wStepCounter] and a