diff options
author | Rangi <remy.oukaour+rangi42@gmail.com> | 2020-07-06 21:18:22 -0400 |
---|---|---|
committer | Rangi <remy.oukaour+rangi42@gmail.com> | 2020-07-06 21:18:22 -0400 |
commit | 06db7ec55bbc87ed18db72a53fb20fa7b4da9b29 (patch) | |
tree | d9631415d7640c39b8883766fa5209f92912c95c /engine/battle | |
parent | 77ed5f3820301f9f301f12bf2f201d9bdab9e7e1 (diff) |
callba/callab -> farcall/callfar; jpba/jpab -> farjp/jpfar
Diffstat (limited to 'engine/battle')
-rw-r--r-- | engine/battle/common_text.asm | 8 | ||||
-rwxr-xr-x | engine/battle/core.asm | 58 | ||||
-rw-r--r-- | engine/battle/effects.asm | 28 | ||||
-rwxr-xr-x | engine/battle/end_of_battle.asm | 2 | ||||
-rw-r--r-- | engine/battle/experience.asm | 16 | ||||
-rw-r--r-- | engine/battle/ghost_marowak_anim.asm | 2 | ||||
-rw-r--r-- | engine/battle/init_battle_variables.asm | 2 | ||||
-rw-r--r-- | engine/battle/link_battle_versus_text.asm | 2 | ||||
-rw-r--r-- | engine/battle/move_effects/drain_hp.asm | 2 | ||||
-rw-r--r-- | engine/battle/move_effects/focus_energy.asm | 4 | ||||
-rw-r--r-- | engine/battle/move_effects/leech_seed.asm | 4 | ||||
-rw-r--r-- | engine/battle/move_effects/mist.asm | 4 | ||||
-rw-r--r-- | engine/battle/move_effects/paralyze.asm | 12 | ||||
-rw-r--r-- | engine/battle/move_effects/substitute.asm | 2 | ||||
-rw-r--r-- | engine/battle/scroll_draw_trainer_pic.asm | 2 | ||||
-rw-r--r-- | engine/battle/trainer_ai.asm | 6 | ||||
-rw-r--r-- | engine/battle/wild_encounters.asm | 4 |
17 files changed, 79 insertions, 79 deletions
diff --git a/engine/battle/common_text.asm b/engine/battle/common_text.asm index b65bb84b..9f6f90b6 100644 --- a/engine/battle/common_text.asm +++ b/engine/battle/common_text.asm @@ -24,7 +24,7 @@ PrintBeginningBattleText: ld hl, TrainerWantsToFightText .wildBattle push hl - callab DrawAllPokeballs + callfar DrawAllPokeballs pop hl call PrintText jr .done @@ -38,7 +38,7 @@ PrintBeginningBattleText: ld a, b and a jr z, .noSilphScope - callab LoadEnemyMonData + callfar LoadEnemyMonData jr .notPokemonTower .noSilphScope ld hl, EnemyAppearedText @@ -54,8 +54,8 @@ PrintBeginningBattleText: call PrintText ld hl, UnveiledGhostText call PrintText - callab LoadEnemyMonData - callab MarowakAnim + callfar LoadEnemyMonData + callfar MarowakAnim ld hl, WildMonAppearedText call PrintText diff --git a/engine/battle/core.asm b/engine/battle/core.asm index 8cb3cd0a..4d999d2a 100755 --- a/engine/battle/core.asm +++ b/engine/battle/core.asm @@ -97,7 +97,7 @@ SlidePlayerAndEnemySilhouettesOnScreen: ld b, SET_PAL_BATTLE call RunPaletteCommand call HideSprites - jpab PrintBeginningBattleText + jpfar PrintBeginningBattleText ; when a battle is starting, silhouettes of the player's pic and the enemy's pic are slid onto the screen ; the lower of the player's pic (his body) is part of the background, but his head is a sprite @@ -178,7 +178,7 @@ StartBattle: ld hl, .outOfSafariBallsText jp PrintText .notOutOfSafariBalls - callab PrintSafariZoneBattleText + callfar PrintSafariZoneBattleText ld a, [wEnemyMonSpeed + 1] add a ld b, a ; init b (which is later compared with random value) to (enemy speed % 256) * 2 @@ -267,7 +267,7 @@ EnemyRan: call PlaySoundWaitForCurrent xor a ldh [hWhoseTurn], a - jpab AnimationSlideEnemyMonOff + jpfar AnimationSlideEnemyMonOff WildRanText: text_far _WildRanText @@ -365,7 +365,7 @@ MainInBattleLoop: jr nz, .specialMoveNotUsed ld [wPlayerSelectedMove], a .specialMoveNotUsed - callab SwitchEnemyMon + callfar SwitchEnemyMon .noLinkBattle ld a, [wPlayerSelectedMove] cp QUICK_ATTACK @@ -413,7 +413,7 @@ MainInBattleLoop: .enemyMovesFirst ld a, $1 ldh [hWhoseTurn], a - callab TrainerAI + callfar TrainerAI jr c, .AIActionUsedEnemyFirst call ExecuteEnemyMove ld a, [wEscapedFromBattle] @@ -451,7 +451,7 @@ MainInBattleLoop: call DrawHUDsAndHPBars ld a, $1 ldh [hWhoseTurn], a - callab TrainerAI + callfar TrainerAI jr c, .AIActionUsedPlayerFirst call ExecuteEnemyMove ld a, [wEscapedFromBattle] @@ -837,7 +837,7 @@ FaintEnemyPokemon: .giveExpToMonsThatFought xor a ld [wBoostExpByExpAll], a - callab GainExperience + callfar GainExperience pop af ret z ; return if no exp all @@ -855,7 +855,7 @@ FaintEnemyPokemon: jr nz, .gainExpFlagsLoop ld a, b ld [wPartyGainExpFlags], a - jpab GainExperience + jpfar GainExperience EnemyMonFaintedText: text_far _EnemyMonFaintedText @@ -893,7 +893,7 @@ ReplaceFaintedEnemyMon: ld hl, wEnemyHPBarColor ld e, $30 call GetBattleHealthBarColor - callab DrawEnemyPokeballs + callfar DrawEnemyPokeballs ld a, [wLinkState] cp LINK_STATE_BATTLING jr nz, .notLinkBattle @@ -1720,7 +1720,7 @@ LoadEnemyMonFromParty: ret SendOutMon: - callab PrintSendOutMonMessage + callfar PrintSendOutMonMessage ld hl, wEnemyMonHP ld a, [hli] or [hl] ; is enemy mon HP zero? @@ -1816,7 +1816,7 @@ DrawPlayerHUDAndHPBar: coord hl, 9, 7 lb bc, 5, 11 call ClearScreenArea - callab PlacePlayerHUDTiles + callfar PlacePlayerHUDTiles coord hl, 18, 9 ld [hl], $73 ld de, wBattleMonNick @@ -1877,7 +1877,7 @@ DrawEnemyHUDAndHPBar: coord hl, 0, 0 lb bc, 4, 12 call ClearScreenArea - callab PlaceEnemyHUDTiles + callfar PlaceEnemyHUDTiles ld de, wEnemyMonNick coord hl, 1, 0 call CenterMonName @@ -2411,7 +2411,7 @@ PartyMenuOrRockOrRun: ; fall through to SwitchPlayerMon SwitchPlayerMon: - callab RetreatMon + callfar RetreatMon ld c, 50 call DelayFrames call AnimateRetreatingPlayerMon @@ -2464,7 +2464,7 @@ MoveSelectionMenu: ld de, wMoves ld bc, NUM_MOVES call CopyData - callab FormatMovesString + callfar FormatMovesString ret .writemoves @@ -2860,7 +2860,7 @@ PrintMenuItem: ld [wWhichPokemon], a ld a, BATTLE_MON_DATA ld [wMonDataLocation], a - callab GetMaxPP + callfar GetMaxPP ld hl, wCurrentMenuItem ld c, [hl] inc [hl] @@ -2955,7 +2955,7 @@ SelectEnemyMove: ld a, [wIsInBattle] dec a jr z, .chooseRandomMove ; wild encounter - callab AIEnemyTrainerChooseMoves + callfar AIEnemyTrainerChooseMoves .chooseRandomMove push hl call BattleRandom @@ -3020,7 +3020,7 @@ LinkBattleExchangeData: ld a, b .doExchange ld [wSerialExchangeNybbleSendData], a - callab PrintWaitingText + callfar PrintWaitingText .syncLoop1 call Serial_ExchangeNybble call DelayFrame @@ -3196,7 +3196,7 @@ MirrorMoveCheck: .moveDidNotMiss call ApplyAttackToEnemyPokemon call PrintCriticalOHKOText - callab DisplayEffectiveness + callfar DisplayEffectiveness ld a, 1 ld [wMoveDidntMiss], a .notDone @@ -4988,7 +4988,7 @@ AttackSubstitute: ldh a, [hWhoseTurn] xor $01 ldh [hWhoseTurn], a - callab HideSubstituteShowMonAnim ; animate the substitute breaking + callfar HideSubstituteShowMonAnim ; animate the substitute breaking ; flip the turn back to the way it was ldh a, [hWhoseTurn] xor $01 @@ -5726,7 +5726,7 @@ EnemyCheckIfMirrorMoveEffect: .moveDidNotMiss call ApplyAttackToPlayerPokemon call PrintCriticalOHKOText - callab DisplayEffectiveness + callfar DisplayEffectiveness ld a, 1 ld [wMoveDidntMiss], a .handleExplosionMiss @@ -6254,14 +6254,14 @@ DoBattleTransitionAndInitBattleVariables: ; link battle xor a ld [wMenuJoypadPollCount], a - callab DisplayLinkBattleVersusTextBox + callfar DisplayLinkBattleVersusTextBox ld a, $1 ld [wUpdateSpritesEnabled], a call ClearScreen .next call DelayFrame predef BattleTransition - callab LoadHudAndHpBarAndStatusTilePatterns + callfar LoadHudAndHpBarAndStatusTilePatterns ld a, $1 ldh [hAutoBGTransferEnabled], a ld a, $ff @@ -6359,11 +6359,11 @@ LoadPlayerBackPic: ; does nothing since no stats are ever selected (barring glitches) DoubleOrHalveSelectedStats: - callab DoubleSelectedStats - jpab HalveSelectedStats + callfar DoubleSelectedStats + jpfar HalveSelectedStats ScrollTrainerPicAfterBattle: - jpab _ScrollTrainerPicAfterBattle + jpfar _ScrollTrainerPicAfterBattle ApplyBurnAndParalysisPenaltiesToPlayer: ld a, $1 @@ -6747,7 +6747,7 @@ DetermineWildOpponent: ld a, [wNumberOfNoRandomBattleStepsLeft] and a ret nz - callab TryDoWildEncounter + callfar TryDoWildEncounter ret nz InitBattleCommon: ld a, [wMapPalOffset] @@ -6756,13 +6756,13 @@ InitBattleCommon: ld a, [hl] push af res 1, [hl] - callab InitBattleVariables + callfar InitBattleVariables ld a, [wEnemyMonSpecies2] sub OPP_ID_OFFSET jp c, InitWildBattle ld [wTrainerClass], a call GetTrainerInformation - callab ReadTrainer + callfar ReadTrainer call DoBattleTransitionAndInitBattleVariables call _LoadTrainerPic xor a @@ -6857,7 +6857,7 @@ _InitBattleCommon: dec a ; is it a wild battle? call z, DrawEnemyHUDAndHPBar ; draw enemy HUD and HP bar if it's a wild battle call StartBattle - callab EndOfBattle + callfar EndOfBattle pop af ld [wLetterPrintingDelayFlags], a pop af diff --git a/engine/battle/effects.asm b/engine/battle/effects.asm index c3a2a213..fe050937 100644 --- a/engine/battle/effects.asm +++ b/engine/battle/effects.asm @@ -170,7 +170,7 @@ BadlyPoisonedText: text_end DrainHPEffect: - jpab DrainHPEffect_ + jpfar DrainHPEffect_ ExplodeEffect: ld hl, wBattleMonHP @@ -987,7 +987,7 @@ FlinchSideEffect: ret OneHitKOEffect: - jpab OneHitKOEffect_ + jpfar OneHitKOEffect_ ChargeEffect: ld hl, wPlayerBattleStatus1 @@ -1097,13 +1097,13 @@ TrappingEffect: ret MistEffect: - jpab MistEffect_ + jpfar MistEffect_ FocusEnergyEffect: - jpab FocusEnergyEffect_ + jpfar FocusEnergyEffect_ RecoilEffect: - jpab RecoilEffect_ + jpfar RecoilEffect_ ConfusionSideEffect: call BattleRandom @@ -1157,10 +1157,10 @@ ConfusionEffectFailed: jp ConditionalPrintButItFailed ParalyzeEffect: - jpab ParalyzeEffect_ + jpfar ParalyzeEffect_ SubstituteEffect: - jpab SubstituteEffect_ + jpfar SubstituteEffect_ HyperBeamEffect: ld hl, wPlayerBattleStatus2 @@ -1271,7 +1271,7 @@ MimicLearnedMoveText: text_end LeechSeedEffect: - jpab LeechSeedEffect_ + jpfar LeechSeedEffect_ SplashEffect: call PlayCurrentMoveAnimation @@ -1365,22 +1365,22 @@ MoveWasDisabledText: text_end PayDayEffect: - jpab PayDayEffect_ + jpfar PayDayEffect_ ConversionEffect: - jpab ConversionEffect_ + jpfar ConversionEffect_ HazeEffect: - jpab HazeEffect_ + jpfar HazeEffect_ HealEffect: - jpab HealEffect_ + jpfar HealEffect_ TransformEffect: - jpab TransformEffect_ + jpfar TransformEffect_ ReflectLightScreenEffect: - jpab ReflectLightScreenEffect_ + jpfar ReflectLightScreenEffect_ NothingHappenedText: text_far _NothingHappenedText diff --git a/engine/battle/end_of_battle.asm b/engine/battle/end_of_battle.asm index f490c34d..aa96f31d 100755 --- a/engine/battle/end_of_battle.asm +++ b/engine/battle/end_of_battle.asm @@ -10,7 +10,7 @@ EndOfBattle: ld a, [wEnemyMonStatus] ld [hl], a call ClearScreen - callab DisplayLinkBattleVersusTextBox + callfar DisplayLinkBattleVersusTextBox ld a, [wBattleResult] cp $1 ld de, YouWinText diff --git a/engine/battle/experience.asm b/engine/battle/experience.asm index 2e21d874..0eab6e08 100644 --- a/engine/battle/experience.asm +++ b/engine/battle/experience.asm @@ -117,7 +117,7 @@ GainExperience: ld [wd0b5], a call GetMonHeader ld d, MAX_LEVEL - callab CalcExperience ; get max exp + callfar CalcExperience ; get max exp ; compare max exp with current exp ldh a, [hExperience] ld b, a @@ -155,7 +155,7 @@ GainExperience: ld bc, wPartyMon1Level - wPartyMon1Exp add hl, bc push hl - callba CalcLevelFromExperience + farcall CalcLevelFromExperience pop hl ld a, [hl] ; current level cp d @@ -233,11 +233,11 @@ GainExperience: .recalcStatChanges xor a ; battle mon ld [wCalculateWhoseStats], a - callab CalculateModifiedStats - callab ApplyBurnAndParalysisPenaltiesToPlayer - callab ApplyBadgeStatBoosts - callab DrawPlayerHUDAndHPBar - callab PrintEmptyString + callfar CalculateModifiedStats + callfar ApplyBurnAndParalysisPenaltiesToPlayer + callfar ApplyBadgeStatBoosts + callfar DrawPlayerHUDAndHPBar + callfar PrintEmptyString call SaveScreenTilesToBuffer1 .printGrewLevelText ld hl, GrewLevelText @@ -246,7 +246,7 @@ GainExperience: ld [wMonDataLocation], a call LoadMonData ld d, $1 - callab PrintStatsBox + callfar PrintStatsBox call WaitForTextScrollButtonPress call LoadScreenTilesFromBuffer1 xor a ; PLAYER_PARTY_DATA diff --git a/engine/battle/ghost_marowak_anim.asm b/engine/battle/ghost_marowak_anim.asm index bef680fe..9c47fd53 100644 --- a/engine/battle/ghost_marowak_anim.asm +++ b/engine/battle/ghost_marowak_anim.asm @@ -15,7 +15,7 @@ MarowakAnim: ld [wChangeMonPicEnemyTurnSpecies], a ld a, $1 ldh [hWhoseTurn], a - callab ChangeMonPic + callfar ChangeMonPic ; alternate between black and light grey 8 times. ; this makes the ghost's body appear to flash ld d, $80 diff --git a/engine/battle/init_battle_variables.asm b/engine/battle/init_battle_variables.asm index d670319c..0d403b55 100644 --- a/engine/battle/init_battle_variables.asm +++ b/engine/battle/init_battle_variables.asm @@ -35,4 +35,4 @@ InitBattleVariables: ld a, BATTLE_TYPE_SAFARI ld [wBattleType], a .notSafariBattle - jpab PlayBattleMusic + jpfar PlayBattleMusic diff --git a/engine/battle/link_battle_versus_text.asm b/engine/battle/link_battle_versus_text.asm index 76559117..22fec0f3 100644 --- a/engine/battle/link_battle_versus_text.asm +++ b/engine/battle/link_battle_versus_text.asm @@ -18,6 +18,6 @@ DisplayLinkBattleVersusTextBox: ld [hl], $6a xor a ld [wUpdateSpritesEnabled], a - callab SetupPlayerAndEnemyPokeballs + callfar SetupPlayerAndEnemyPokeballs ld c, 150 jp DelayFrames diff --git a/engine/battle/move_effects/drain_hp.asm b/engine/battle/move_effects/drain_hp.asm index 74e5d376..e7b241f6 100644 --- a/engine/battle/move_effects/drain_hp.asm +++ b/engine/battle/move_effects/drain_hp.asm @@ -81,7 +81,7 @@ DrainHPEffect_: predef UpdateHPBar2 predef DrawPlayerHUDAndHPBar predef DrawEnemyHUDAndHPBar - callab ReadPlayerMonCurHPAndStatus + callfar ReadPlayerMonCurHPAndStatus ld hl, SuckedHealthText ldh a, [hWhoseTurn] and a diff --git a/engine/battle/move_effects/focus_energy.asm b/engine/battle/move_effects/focus_energy.asm index fd04e024..1fafe920 100644 --- a/engine/battle/move_effects/focus_energy.asm +++ b/engine/battle/move_effects/focus_energy.asm @@ -8,13 +8,13 @@ FocusEnergyEffect_: bit GETTING_PUMPED, [hl] ; is mon already using focus energy? jr nz, .alreadyUsing set GETTING_PUMPED, [hl] ; mon is now using focus energy - callab PlayCurrentMoveAnimation + callfar PlayCurrentMoveAnimation ld hl, GettingPumpedText jp PrintText .alreadyUsing ld c, 50 call DelayFrames - jpab PrintButItFailedText_ + jpfar PrintButItFailedText_ GettingPumpedText: text_pause diff --git a/engine/battle/move_effects/leech_seed.asm b/engine/battle/move_effects/leech_seed.asm index 061c0073..61bd982a 100644 --- a/engine/battle/move_effects/leech_seed.asm +++ b/engine/battle/move_effects/leech_seed.asm @@ -1,5 +1,5 @@ LeechSeedEffect_: - callab MoveHitTest + callfar MoveHitTest ld a, [wMoveMissed] and a jr nz, .moveMissed @@ -22,7 +22,7 @@ LeechSeedEffect_: bit SEEDED, [hl] jr nz, .moveMissed set SEEDED, [hl] - callab PlayCurrentMoveAnimation + callfar PlayCurrentMoveAnimation ld hl, WasSeededText jp PrintText .moveMissed diff --git a/engine/battle/move_effects/mist.asm b/engine/battle/move_effects/mist.asm index a9cb21b8..163d386f 100644 --- a/engine/battle/move_effects/mist.asm +++ b/engine/battle/move_effects/mist.asm @@ -8,11 +8,11 @@ MistEffect_: bit PROTECTED_BY_MIST, [hl] ; is mon protected by mist? jr nz, .mistAlreadyInUse set PROTECTED_BY_MIST, [hl] ; mon is now protected by mist - callab PlayCurrentMoveAnimation + callfar PlayCurrentMoveAnimation ld hl, ShroudedInMistText jp PrintText .mistAlreadyInUse - jpab PrintButItFailedText_ + jpfar PrintButItFailedText_ ShroudedInMistText: text_far _ShroudedInMistText diff --git a/engine/battle/move_effects/paralyze.asm b/engine/battle/move_effects/paralyze.asm index d828e333..dbaa0fb8 100644 --- a/engine/battle/move_effects/paralyze.asm +++ b/engine/battle/move_effects/paralyze.asm @@ -26,22 +26,22 @@ ParalyzeEffect_: jr z, .doesntAffect .hitTest push hl - callab MoveHitTest + callfar MoveHitTest pop hl ld a, [wMoveMissed] and a jr nz, .didntAffect set PAR, [hl] - callab QuarterSpeedDueToParalysis + callfar QuarterSpeedDueToParalysis ld c, 30 call DelayFrames - callab PlayCurrentMoveAnimation - jpab PrintMayNotAttackText + callfar PlayCurrentMoveAnimation + jpfar PrintMayNotAttackText .didntAffect ld c, 50 call DelayFrames - jpab PrintDidntAffectText + jpfar PrintDidntAffectText .doesntAffect ld c, 50 call DelayFrames - jpab PrintDoesntAffectText + jpfar PrintDoesntAffectText diff --git a/engine/battle/move_effects/substitute.asm b/engine/battle/move_effects/substitute.asm index eb6d0e89..860b76b6 100644 --- a/engine/battle/move_effects/substitute.asm +++ b/engine/battle/move_effects/substitute.asm @@ -55,7 +55,7 @@ SubstituteEffect_: call Bankswitch ; jump to routine depending on animation setting ld hl, SubstituteText call PrintText - jpab DrawHUDsAndHPBars + jpfar DrawHUDsAndHPBars .alreadyHasSubstitute ld hl, HasSubstituteText jr .printText diff --git a/engine/battle/scroll_draw_trainer_pic.asm b/engine/battle/scroll_draw_trainer_pic.asm index 98893dcf..978fb71a 100644 --- a/engine/battle/scroll_draw_trainer_pic.asm +++ b/engine/battle/scroll_draw_trainer_pic.asm @@ -5,7 +5,7 @@ _ScrollTrainerPicAfterBattle: ld [wEnemyMonSpecies2], a ld b, SET_PAL_BATTLE call RunPaletteCommand - callab _LoadTrainerPic + callfar _LoadTrainerPic coord hl, 19, 0 ld c, $0 .scrollLoop diff --git a/engine/battle/trainer_ai.asm b/engine/battle/trainer_ai.asm index 3e444f8b..ea476538 100644 --- a/engine/battle/trainer_ai.asm +++ b/engine/battle/trainer_ai.asm @@ -204,7 +204,7 @@ AIMoveChoiceModification3: push hl push bc push de - callab AIGetTypeEffectiveness + callfar AIGetTypeEffectiveness pop de pop bc pop hl @@ -599,7 +599,7 @@ SwitchEnemyMon: ; switching in a new mon in response to this switch. ld a, 1 ld [wFirstMonsNotOutYet], a - callab EnemySendOut + callfar EnemySendOut xor a ld [wFirstMonsNotOutYet], a @@ -713,7 +713,7 @@ AIIncreaseStat: ld a, ANIM_AF ld [hli], a ld [hl], b - callab StatModifierUpEffect + callfar StatModifierUpEffect pop hl pop af ld [hli], a diff --git a/engine/battle/wild_encounters.asm b/engine/battle/wild_encounters.asm index 9b637f97..3d0eb556 100644 --- a/engine/battle/wild_encounters.asm +++ b/engine/battle/wild_encounters.asm @@ -7,14 +7,14 @@ TryDoWildEncounter: ld a, [wd736] and a ret nz - callab IsPlayerStandingOnDoorTileOrWarpTile + callfar IsPlayerStandingOnDoorTileOrWarpTile jr nc, .notStandingOnDoorOrWarpTile .CantEncounter ld a, $1 and a ret .notStandingOnDoorOrWarpTile - callab IsPlayerJustOutsideMap + callfar IsPlayerJustOutsideMap jr z, .CantEncounter ld a, [wRepelRemainingSteps] and a |