Prefix wram labels with w, part 2.

This commit is contained in:
luckytyphlosion
2018-01-23 17:39:09 -05:00
parent 79bd48f85c
commit a1951cefc0
323 changed files with 8581 additions and 8581 deletions

View File

@@ -10,13 +10,13 @@ DrawHP: ; 50b10
push hl
push bc
; box mons have full HP
ld a, [MonType]
ld a, [wMonType]
cp BOXMON
jr z, .at_least_1_hp
ld a, [TempMonHP]
ld a, [wTempMonHP]
ld b, a
ld a, [TempMonHP + 1]
ld a, [wTempMonHP + 1]
ld c, a
; Any HP?
@@ -31,11 +31,11 @@ DrawHP: ; 50b10
jp .fainted
.at_least_1_hp
ld a, [TempMonMaxHP]
ld a, [wTempMonMaxHP]
ld d, a
ld a, [TempMonMaxHP + 1]
ld a, [wTempMonMaxHP + 1]
ld e, a
ld a, [MonType]
ld a, [wMonType]
cp BOXMON
jr nz, .not_boxmon
@@ -62,11 +62,11 @@ DrawHP: ; 50b10
; Print HP
bccoord 1, 1, 0
add hl, bc
ld de, TempMonHP
ld a, [MonType]
ld de, wTempMonHP
ld a, [wMonType]
cp BOXMON
jr nz, .not_boxmon_2
ld de, TempMonMaxHP
ld de, wTempMonMaxHP
.not_boxmon_2
lb bc, 2, 3
call PrintNum
@@ -75,7 +75,7 @@ DrawHP: ; 50b10
ld [hli], a
; Print max HP
ld de, TempMonMaxHP
ld de, wTempMonMaxHP
lb bc, 2, 3
call PrintNum
pop hl
@@ -83,7 +83,7 @@ DrawHP: ; 50b10
ret
PrintTempMonStats: ; 50b7b
; Print TempMon's stats at hl, with spacing bc.
; Print wTempMon's stats at hl, with spacing bc.
push bc
push hl
ld de, .StatNames
@@ -93,16 +93,16 @@ PrintTempMonStats: ; 50b7b
add hl, bc
ld bc, SCREEN_WIDTH
add hl, bc
ld de, TempMonAttack
ld de, wTempMonAttack
lb bc, 2, 3
call .PrintStat
ld de, TempMonDefense
ld de, wTempMonDefense
call .PrintStat
ld de, TempMonSpclAtk
ld de, wTempMonSpclAtk
call .PrintStat
ld de, TempMonSpclDef
ld de, wTempMonSpclDef
call .PrintStat
ld de, TempMonSpeed
ld de, wTempMonSpeed
jp PrintNum
.PrintStat: ; 50bab
@@ -122,8 +122,8 @@ PrintTempMonStats: ; 50b7b
next "@"
GetGender: ; 50bdd
; Return the gender of a given monster (CurPartyMon/CurOTMon/CurWildMon).
; When calling this function, a should be set to an appropriate MonType value.
; Return the gender of a given monster (wCurPartyMon/wCurOTMon/CurWildMon).
; When calling this function, a should be set to an appropriate wMonType value.
; return values:
; a = 1: f = nc|nz; male
@@ -136,14 +136,14 @@ GetGender: ; 50bdd
; Figure out what type of monster struct we're looking at.
; 0: PartyMon
ld hl, PartyMon1DVs
ld hl, wPartyMon1DVs
ld bc, PARTYMON_STRUCT_LENGTH
ld a, [MonType]
ld a, [wMonType]
and a
jr z, .PartyMon
; 1: OTPartyMon
ld hl, OTPartyMon1DVs
ld hl, wOTPartyMon1DVs
dec a
jr z, .PartyMon
@@ -154,25 +154,25 @@ GetGender: ; 50bdd
jr z, .sBoxMon
; 3: Unknown
ld hl, TempMonDVs
ld hl, wTempMonDVs
dec a
jr z, .DVs
; else: WildMon
ld hl, EnemyMonDVs
ld hl, wEnemyMonDVs
jr .DVs
; Get our place in the party/box.
.PartyMon:
.sBoxMon
ld a, [CurPartyMon]
ld a, [wCurPartyMon]
call AddNTimes
.DVs:
; sBoxMon data is read directly from SRAM.
ld a, [MonType]
ld a, [wMonType]
cp BOXMON
ld a, BANK(sBox)
call z, GetSRAMBank
@@ -191,13 +191,13 @@ GetGender: ; 50bdd
ld b, a
; Close SRAM if we were dealing with a sBoxMon.
ld a, [MonType]
ld a, [wMonType]
cp BOXMON
call z, CloseSRAM
; We need the gender ratio to do anything with this.
push bc
ld a, [CurPartySpecies]
ld a, [wCurPartySpecies]
dec a
ld hl, BaseData + BASE_GENDER
ld bc, BASE_DATA_SIZE
@@ -243,7 +243,7 @@ ListMovePP: ; 50c50
sub c
ld b, a
push hl
ld a, [Buffer1]
ld a, [wBuffer1]
ld e, a
ld d, $0
ld a, $3e ; P
@@ -262,7 +262,7 @@ ListMovePP: ; 50c50
inc hl
ld d, h
ld e, l
ld hl, TempMonMoves
ld hl, wTempMonMoves
ld b, 0
.loop
ld a, [hli]
@@ -283,15 +283,15 @@ ListMovePP: ; 50c50
pop de
pop hl
push hl
ld bc, TempMonPP - (TempMonMoves + 1)
ld bc, wTempMonPP - (wTempMonMoves + 1)
add hl, bc
ld a, [hl]
and $3f
ld [StringBuffer1 + 4], a
ld [wStringBuffer1 + 4], a
ld h, d
ld l, e
push hl
ld de, StringBuffer1 + 4
ld de, wStringBuffer1 + 4
lb bc, 1, 2
call PrintNum
ld a, "/"
@@ -300,7 +300,7 @@ ListMovePP: ; 50c50
lb bc, 1, 2
call PrintNum
pop hl
ld a, [Buffer1]
ld a, [wBuffer1]
ld e, a
ld d, 0
add hl, de
@@ -338,14 +338,14 @@ Unreferenced_Function50cd0: ; 50cd0
Unused_PlaceEnemyHPLevel:
push hl
push hl
ld hl, PartyMonNicknames
ld a, [CurPartyMon]
ld hl, wPartyMonNicknames
ld a, [wCurPartyMon]
call GetNick
pop hl
call PlaceString
call CopyPkmnToTempMon
pop hl
ld a, [CurPartySpecies]
ld a, [wCurPartySpecies]
cp EGG
jr z, .egg
push hl
@@ -431,7 +431,7 @@ FrzString: db "FRZ@"
ParString: db "PAR@"
ListMoves: ; 50d6f
; List moves at hl, spaced every [Buffer1] tiles.
; List moves at hl, spaced every [wBuffer1] tiles.
ld de, wListMoves_MoveIndicesBuffer
ld b, $0
.moves_loop
@@ -442,11 +442,11 @@ ListMoves: ; 50d6f
push de
push hl
push hl
ld [CurSpecies], a
ld [wCurSpecies], a
ld a, MOVE_NAME
ld [wNamedObjectTypeBuffer], a
call GetName
ld de, StringBuffer1
ld de, wStringBuffer1
pop hl
push bc
call PlaceString
@@ -456,7 +456,7 @@ ListMoves: ; 50d6f
inc b
pop hl
push bc
ld a, [Buffer1]
ld a, [wBuffer1]
ld c, a
ld b, 0
add hl, bc
@@ -472,7 +472,7 @@ ListMoves: ; 50d6f
.nonmove_loop
push af
ld [hl], "-"
ld a, [Buffer1]
ld a, [wBuffer1]
ld c, a
ld b, 0
add hl, bc