You've already forked pokecrystal-board
mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2025-12-11 05:02:16 -08:00
Consistent if/else/endc (matches rept/endr) and DEF (matches BANK/HIGH/LOW)
This commit is contained in:
@@ -1442,9 +1442,9 @@ copy_box_data: MACRO
|
||||
jr .loop\@
|
||||
|
||||
.done\@
|
||||
IF \1
|
||||
if \1
|
||||
call CloseSRAM
|
||||
ENDC
|
||||
endc
|
||||
ld a, -1
|
||||
ld [de], a
|
||||
ld a, [wd004]
|
||||
|
||||
@@ -26,13 +26,13 @@ Function_LoadOpponentTrainerAndPokemons: ; 1f8000
|
||||
ld a, [hRandomAdd]
|
||||
add b
|
||||
ld b, a ; b contains the nr of the trainer
|
||||
IF DEF(CRYSTAL11)
|
||||
if DEF(CRYSTAL11)
|
||||
and (1 << 7) - 1
|
||||
cp 70
|
||||
ELSE
|
||||
else
|
||||
and (1 << 5) - 1
|
||||
cp 21
|
||||
ENDC
|
||||
endc
|
||||
jr nc, .resample
|
||||
ld b, a
|
||||
|
||||
|
||||
@@ -199,9 +199,9 @@ _ResetWRAM: ; 5bae
|
||||
ld [Coins], a
|
||||
ld [Coins + 1], a
|
||||
|
||||
IF START_MONEY >= $10000
|
||||
if START_MONEY >= $10000
|
||||
ld a, HIGH(START_MONEY >> 8)
|
||||
ENDC
|
||||
endc
|
||||
ld [Money], a
|
||||
ld a, HIGH(START_MONEY) ; mid
|
||||
ld [Money + 1], a
|
||||
@@ -646,11 +646,11 @@ Continue_DisplayPokedexNumCaught: ; 5f6b
|
||||
ret z
|
||||
push hl
|
||||
ld hl, PokedexCaught
|
||||
IF NUM_POKEMON % 8
|
||||
if NUM_POKEMON % 8
|
||||
ld b, NUM_POKEMON / 8 + 1
|
||||
ELSE
|
||||
else
|
||||
ld b, NUM_POKEMON / 8
|
||||
ENDC
|
||||
endc
|
||||
call CountSetBits
|
||||
pop hl
|
||||
ld de, wd265
|
||||
|
||||
@@ -55,7 +55,7 @@ AnimateMon_Unused: ; d003a
|
||||
pokeanim: MACRO
|
||||
rept _NARG
|
||||
; Workaround for a bug where macro args can't come after the start of a symbol
|
||||
if !def(\1_POKEANIM)
|
||||
if !DEF(\1_POKEANIM)
|
||||
\1_POKEANIM EQUS "PokeAnim_\1_"
|
||||
endc
|
||||
db (\1_POKEANIM - PokeAnim_SetupCommands) / 2
|
||||
|
||||
@@ -147,9 +147,9 @@ ScriptCommandTable:
|
||||
dw Script_loadmenudata ; 4f
|
||||
dw Script_closewindow ; 50
|
||||
dw Script_jumptextfaceplayer ; 51
|
||||
IF _CRYSTAL
|
||||
if _CRYSTAL
|
||||
dw Script_farjumptext ; 52
|
||||
ENDC
|
||||
endc
|
||||
dw Script_jumptext ; 53
|
||||
dw Script_waitbutton ; 54
|
||||
dw Script_buttonsound ; 55
|
||||
@@ -338,7 +338,7 @@ JumpTextScript:
|
||||
end
|
||||
|
||||
|
||||
IF _CRYSTAL
|
||||
if _CRYSTAL
|
||||
|
||||
Script_farjumptext:
|
||||
; script command 0x52
|
||||
@@ -355,7 +355,7 @@ Script_farjumptext:
|
||||
ld hl, JumpTextScript
|
||||
jp ScriptJump
|
||||
|
||||
ENDC
|
||||
endc
|
||||
|
||||
|
||||
Script_writetext:
|
||||
|
||||
Reference in New Issue
Block a user