Skip to content

Commit

Permalink
Lowercase v for VRAM addresses
Browse files Browse the repository at this point in the history
  • Loading branch information
xCrystal committed Dec 28, 2017
1 parent 7beb497 commit 333524f
Show file tree
Hide file tree
Showing 86 changed files with 537 additions and 537 deletions.
2 changes: 1 addition & 1 deletion data/emotes.asm
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ emote: MACRO
; graphics pointer, length, starting tile
dw \1
db \2 tiles, BANK(\1)
dw VTiles1 tile \3
dw vTiles1 tile \3
ENDM

Emotes: ; 144d
Expand Down
4 changes: 2 additions & 2 deletions engine/battle/battle_transition.asm
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ LoadTrainerBattlePokeballTiles:
; Load the tiles used in the Pokeball Graphic that fills the screen
; at the start of every Trainer battle.
ld de, TrainerBattlePokeballTiles
ld hl, VTiles1 tile $7e
ld hl, vTiles1 tile $7e
ld b, BANK(TrainerBattlePokeballTiles)
ld c, 2
call Request2bpp
Expand All @@ -103,7 +103,7 @@ LoadTrainerBattlePokeballTiles:
ld [rVBK], a

ld de, TrainerBattlePokeballTiles
ld hl, VTiles4 tile $7e
ld hl, vTiles4 tile $7e
ld b, BANK(TrainerBattlePokeballTiles)
ld c, 2
call Request2bpp
Expand Down
50 changes: 25 additions & 25 deletions engine/battle/core.asm
Original file line number Diff line number Diff line change
Expand Up @@ -5309,13 +5309,13 @@ BattleMenuPKMN_Loop:
Battle_StatsScreen: ; 3e308
call DisableLCD

ld hl, VTiles2 tile $31
ld de, VTiles0
ld hl, vTiles2 tile $31
ld de, vTiles0
ld bc, $11 tiles
call CopyBytes

ld hl, VTiles2
ld de, VTiles0 tile $11
ld hl, vTiles2
ld de, vTiles0 tile $11
ld bc, $31 tiles
call CopyBytes

Expand All @@ -5330,13 +5330,13 @@ Battle_StatsScreen: ; 3e308

call DisableLCD

ld hl, VTiles0
ld de, VTiles2 tile $31
ld hl, vTiles0
ld de, vTiles2 tile $31
ld bc, $11 tiles
call CopyBytes

ld hl, VTiles0 tile $11
ld de, VTiles2
ld hl, vTiles0 tile $11
ld de, vTiles2
ld bc, $31 tiles
call CopyBytes

Expand Down Expand Up @@ -6779,7 +6779,7 @@ BattleWinSlideInEnemyTrainerFrontpic: ; 3ebd8
call FinishBattleAnim
ld a, [OtherTrainerClass]
ld [TrainerClass], a
ld de, VTiles2
ld de, vTiles2
callfar GetTrainerPic
hlcoord 19, 0
ld c, 0
Expand Down Expand Up @@ -7155,15 +7155,15 @@ _LoadHPBar: ; 3eda6

LoadHPExpBarGFX: ; unreferenced
ld de, EnemyHPBarBorderGFX
ld hl, VTiles2 tile $6c
ld hl, vTiles2 tile $6c
lb bc, BANK(EnemyHPBarBorderGFX), 4
call Get1bpp
ld de, HPExpBarBorderGFX
ld hl, VTiles2 tile $73
ld hl, vTiles2 tile $73
lb bc, BANK(HPExpBarBorderGFX), 6
call Get1bpp
ld de, ExpBarGFX
ld hl, VTiles2 tile $55
ld hl, vTiles2 tile $55
lb bc, BANK(ExpBarGFX), 8
jp Get2bpp
; 3edd1
Expand Down Expand Up @@ -8286,7 +8286,7 @@ DropPlayerSub: ; 3f447
ld [CurPartySpecies], a
ld hl, BattleMonDVs
predef GetUnownLetter
ld de, VTiles2 tile $31
ld de, vTiles2 tile $31
predef GetMonBackpic
pop af
ld [CurPartySpecies], a
Expand Down Expand Up @@ -8325,7 +8325,7 @@ DropEnemySub: ; 3f486
call GetBaseData
ld hl, EnemyMonDVs
predef GetUnownLetter
ld de, VTiles2
ld de, vTiles2
predef GetAnimatedFrontpicPredef
pop af
ld [CurPartySpecies], a
Expand Down Expand Up @@ -8382,7 +8382,7 @@ BattleIntro: ; 3f4dd
call DisableSpriteUpdates
farcall ClearBattleRAM
call InitEnemy
call BackUpVBGMap2
call BackUpBGMap2
ld b, SCGB_BATTLE_GRAYSCALE
call GetSGBLayout
ld hl, rLCDC
Expand Down Expand Up @@ -8428,22 +8428,22 @@ InitEnemy: ; 3f55e
jp InitEnemyWildmon ; wild
; 3f568

BackUpVBGMap2: ; 3f568
BackUpBGMap2: ; 3f568
ld a, [rSVBK]
push af
ld a, $6 ; BANK(wDecompressScratch)
ld [rSVBK], a
ld hl, wDecompressScratch
ld bc, $40 tiles ; VBGMap3 - VBGMap2
ld bc, $40 tiles ; vBGMap3 - vBGMap2
ld a, $2
call ByteFill
ld a, [rVBK]
push af
ld a, $1
ld [rVBK], a
ld de, wDecompressScratch
hlbgcoord 0, 0 ; VBGMap2
lb bc, BANK(BackUpVBGMap2), $40
hlbgcoord 0, 0 ; vBGMap2
lb bc, BANK(BackUpBGMap2), $40
call Request2bpp
pop af
ld [rVBK], a
Expand All @@ -8467,7 +8467,7 @@ InitEnemyTrainer: ; 3f594
ld [OTPartyMon1Item], a
.ok

ld de, VTiles2
ld de, vTiles2
callfar GetTrainerPic
xor a
ld [hGraphicStartTile], a
Expand Down Expand Up @@ -8531,7 +8531,7 @@ InitEnemyWildmon: ; 3f607
ld a, [UnownLetter]
ld [wFirstUnownSeen], a
.skip_unown
ld de, VTiles2
ld de, vTiles2
predef GetAnimatedFrontpicPredef
xor a
ld [TrainerClass], a
Expand Down Expand Up @@ -9336,7 +9336,7 @@ InitBattleDisplay: ; 3fb6c
; 3fbff

GetTrainerBackpic: ; 3fbff
; Load the player character's backpic (6x6) into VRAM starting from VTiles2 tile $31.
; Load the player character's backpic (6x6) into VRAM starting from vTiles2 tile $31.

; Special exception for Dude.
ld b, BANK(DudeBackpic)
Expand All @@ -9363,7 +9363,7 @@ GetTrainerBackpic: ; 3fbff
ld hl, ChrisBackpic

.Decompress:
ld de, VTiles2 tile $31
ld de, vTiles2 tile $31
ld c, $31
predef DecompressPredef
ret
Expand All @@ -9374,8 +9374,8 @@ CopyBackpic: ; 3fc30
push af
ld a, $6
ld [rSVBK], a
ld hl, VTiles0
ld de, VTiles2 tile $31
ld hl, vTiles0
ld de, vTiles2 tile $31
ld a, [hROMBank]
ld b, a
ld c, $31
Expand Down
4 changes: 2 additions & 2 deletions engine/battle/start_battle.asm
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ ClearBattleRAM: ; 2ef18
call ClearWindowData

ld hl, hBGMapAddress
xor a ; LOW(VBGMap0)
xor a ; LOW(vBGMap0)
ld [hli], a
ld [hl], HIGH(VBGMap0)
ld [hl], HIGH(vBGMap0)
ret
2 changes: 1 addition & 1 deletion engine/battle/trainer_huds.asm
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ LoadTrainerHudOAM: ; 2c143

LoadBallIconGFX: ; 2c165
ld de, .gfx
ld hl, VTiles0 tile $31
ld hl, vTiles0 tile $31
lb bc, BANK(LoadBallIconGFX), 4
call Get2bpp_2
ret
Expand Down
48 changes: 24 additions & 24 deletions engine/battle_anims/anim_commands.asm
Original file line number Diff line number Diff line change
Expand Up @@ -236,16 +236,16 @@ Functioncc220: ; cc220
; Appears to be unused.
xor a
ld [hBGMapMode], a
ld a, LOW(VBGMap0 tile $28)
ld a, LOW(vBGMap0 tile $28)
ld [hBGMapAddress], a
ld a, HIGH(VBGMap0 tile $28)
ld a, HIGH(vBGMap0 tile $28)
ld [hBGMapAddress + 1], a
call WaitBGMap2
ld a, $60
ld [hWY], a
xor a ; LOW(VBGMap0)
xor a ; LOW(vBGMap0)
ld [hBGMapAddress], a
ld a, HIGH(VBGMap0)
ld a, HIGH(vBGMap0)
ld [hBGMapAddress + 1], a
call BattleAnimDelayFrame
ret
Expand Down Expand Up @@ -693,7 +693,7 @@ BattleAnimCmd_5GFX: ; cc485 (33:4485)
ld [wBattleAnimTemp0], a
.loop
ld a, [wBattleAnimTemp0]
cp (VTiles1 - VTiles0) / $10 - $31
cp (vTiles1 - vTiles0) / $10 - $31
ret nc
call GetBattleAnimByte
ld [hli], a
Expand All @@ -706,7 +706,7 @@ BattleAnimCmd_5GFX: ; cc485 (33:4485)
rept 4
add hl, hl
endr
ld de, VTiles0 tile $31
ld de, vTiles0 tile $31
add hl, de
ld a, [BattleAnimByte]
call LoadBattleAnimObj
Expand Down Expand Up @@ -816,13 +816,13 @@ BattleAnimCmd_EnemyFeetObj: ; cc52c (33:452c)
ld a, $49
ld [hl], a

ld hl, VTiles0 tile $73
ld de, VTiles2 tile $06
ld hl, vTiles0 tile $73
ld de, vTiles2 tile $06
ld a, $70
ld [wBattleAnimTemp0], a
ld a, $7
call .LoadFootprint
ld de, VTiles2 tile $31
ld de, vTiles2 tile $31
ld a, $60
ld [wBattleAnimTemp0], a
ld a, $6
Expand Down Expand Up @@ -871,13 +871,13 @@ BattleAnimCmd_PlayerHeadObj: ; cc57e (33:457e)
ld a, $43
ld [hl], a

ld hl, VTiles0 tile $66
ld de, VTiles2 tile $05
ld hl, vTiles0 tile $66
ld de, vTiles2 tile $05
ld a, $70
ld [wBattleAnimTemp0], a
ld a, $7
call .LoadHead
ld de, VTiles2 tile $31
ld de, vTiles2 tile $31
ld a, $60
ld [wBattleAnimTemp0], a
ld a, $6
Expand Down Expand Up @@ -930,7 +930,7 @@ BattleAnimCmd_Transform: ; cc5dc (33:45dc)
ld [CurPartySpecies], a ; CurPartySpecies
ld hl, BattleMonDVs ; BattleMonDVs
predef GetUnownLetter
ld de, VTiles0 tile $00
ld de, vTiles0 tile $00
predef GetMonFrontpic
jr .done

Expand All @@ -939,7 +939,7 @@ BattleAnimCmd_Transform: ; cc5dc (33:45dc)
ld [CurPartySpecies], a ; CurPartySpecies
ld hl, EnemyMonDVs ; EnemyMonDVs
predef GetUnownLetter
ld de, VTiles0 tile $00
ld de, vTiles0 tile $00
predef GetMonBackpic

.done
Expand All @@ -951,19 +951,19 @@ BattleAnimCmd_Transform: ; cc5dc (33:45dc)

BattleAnimCmd_UpdateActorPic: ; cc622 (33:4622)

ld de, VTiles0 tile $00
ld de, vTiles0 tile $00
ld a, [hBattleTurn]
and a
jr z, .player

ld hl, VTiles2 tile $00
ld hl, vTiles2 tile $00
ld b, 0
ld c, $31
call Request2bpp
ret

.player
ld hl, VTiles2 tile $31
ld hl, vTiles2 tile $31
ld b, 0
ld c, $24
call Request2bpp
Expand Down Expand Up @@ -1007,7 +1007,7 @@ GetSubstitutePic: ; cc64c
ld de, sScratch + (3 * 7 + 6) tiles
call .CopyTile

ld hl, VTiles2 tile $00
ld hl, vTiles2 tile $00
ld de, sScratch
lb bc, BANK(GetSubstitutePic), 7 * 7
call Request2bpp
Expand All @@ -1027,7 +1027,7 @@ GetSubstitutePic: ; cc64c
ld de, sScratch + (3 * 6 + 5) tiles
call .CopyTile

ld hl, VTiles2 tile $31
ld hl, vTiles2 tile $31
ld de, sScratch
lb bc, BANK(GetSubstitutePic), 6 * 6
call Request2bpp
Expand Down Expand Up @@ -1075,15 +1075,15 @@ GetMinimizePic: ; cc6e7 (33:46e7)

ld de, sScratch + $1a tiles
call CopyMinimizePic
ld hl, VTiles2 tile $00
ld hl, vTiles2 tile $00
ld de, sScratch
lb bc, BANK(GetMinimizePic), $31
ret

.player
ld de, sScratch + $160
call CopyMinimizePic
ld hl, VTiles2 tile $31
ld hl, vTiles2 tile $31
ld de, sScratch
lb bc, BANK(GetMinimizePic), $24
ret
Expand All @@ -1108,7 +1108,7 @@ BattleAnimCmd_Minimize: ; cc735 (33:4735)
xor a
call GetSRAMBank
call GetMinimizePic
ld hl, VTiles0 tile $00
ld hl, vTiles0 tile $00
call Request2bpp
call CloseSRAM
pop af
Expand Down Expand Up @@ -1157,14 +1157,14 @@ BattleAnimCmd_BeatUp: ; cc776 (33:4776)

ld hl, BattleMonDVs
predef GetUnownLetter
ld de, VTiles2 tile $00
ld de, vTiles2 tile $00
predef GetMonFrontpic
jr .done

.player
ld hl, EnemyMonDVs
predef GetUnownLetter
ld de, VTiles2 tile $31
ld de, vTiles2 tile $31
predef GetMonBackpic

.done
Expand Down
Loading

0 comments on commit 333524f

Please sign in to comment.