diff options
author | Rangi <remy.oukaour+rangi42@gmail.com> | 2018-07-23 00:25:53 -0400 |
---|---|---|
committer | Rangi <remy.oukaour+rangi42@gmail.com> | 2018-07-23 00:25:53 -0400 |
commit | 4f0c9cecf9a4c9dec50e2a5fce8392c2217068e0 (patch) | |
tree | 081ebd7f6ebbb71774df8dc151b68901c9bd6d23 /engine/battle/core.asm | |
parent | a1806d6e816369ad5452c4a008d7cd5802f1ec45 (diff) |
StringCmp → CompareBytes; CompareLong → CompareBytesLong
hStringCmpString[1/2] → h[EnemyMon/PartyMon1]Speed
Diffstat (limited to 'engine/battle/core.asm')
-rw-r--r-- | engine/battle/core.asm | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/engine/battle/core.asm b/engine/battle/core.asm index 7e92a3e31..312ba8158 100644 --- a/engine/battle/core.asm +++ b/engine/battle/core.asm @@ -530,7 +530,7 @@ DetermineMoveOrder: ld de, wBattleMonSpeed ld hl, wEnemyMonSpeed ld c, 2 - call StringCmp + call CompareBytes jr z, .speed_tie jp nc, .player_first jp .enemy_first @@ -3715,19 +3715,19 @@ TryToRunAwayFromBattle: inc a ld [wNumFleeAttempts], a ld a, [hli] - ld [hStringCmpString2 + 0], a + ld [hPartyMon1Speed + 0], a ld a, [hl] - ld [hStringCmpString2 + 1], a + ld [hPartyMon1Speed + 1], a ld a, [de] inc de - ld [hStringCmpString1 + 0], a + ld [hEnemyMonSpeed + 0], a ld a, [de] - ld [hStringCmpString1 + 1], a + ld [hEnemyMonSpeed + 1], a call Call_LoadTempTileMapToTileMap - ld de, hStringCmpString2 - ld hl, hStringCmpString1 - ld c, $2 - call StringCmp + ld de, hPartyMon1Speed + ld hl, hEnemyMonSpeed + ld c, 2 + call CompareBytes jr nc, .can_escape xor a @@ -3739,9 +3739,9 @@ TryToRunAwayFromBattle: ld [hDividend + 0], a ld a, [hProduct + 3] ld [hDividend + 1], a - ld a, [hStringCmpString1 + 0] + ld a, [hEnemyMonSpeed + 0] ld b, a - ld a, [hStringCmpString1 + 1] + ld a, [hEnemyMonSpeed + 1] srl b rr a srl b @@ -8712,7 +8712,7 @@ AddLastMobileBattleToLinkRecord: push de ld bc, 12 ld de, wStringBuffer1 - call CompareLong + call CompareBytesLong pop de pop hl jr c, .done @@ -8821,7 +8821,7 @@ AddLastMobileBattleToLinkRecord: pop hl push bc ld c, 3 - call StringCmp + call CompareBytes pop bc jr z, .equal jr nc, .done2 |