From 3c7ba37de72795e46c76f791b50b4a3d89ba0c2c Mon Sep 17 00:00:00 2001 From: luckytyphlosion <10688458+luckytyphlosion@users.noreply.github.com> Date: Tue, 30 Jan 2018 14:47:14 -0500 Subject: [PATCH] Fix wVirtualOAM labels, part 1. --- engine/battle_anims/functions.asm | 6 +++--- engine/routines/loadpushoam.asm | 4 ++-- home/init.asm | 4 ++-- home/vblank.asm | 8 ++++---- hram.asm | 2 +- 5 files changed, 12 insertions(+), 12 deletions(-) diff --git a/engine/battle_anims/functions.asm b/engine/battle_anims/functions.asm index 115147d39..e747feeef 100755 --- a/engine/battle_anims/functions.asm +++ b/engine/battle_anims/functions.asm @@ -1611,7 +1611,7 @@ Functioncd913: ; cd913 (33:5913) ld hl, BATTLEANIMSTRUCT_10 add hl, bc ld e, [hl] - ld hl, hPushOAM ; $ff80 + ld hl, hTransferVirtualOAM ; $ff80 add hl, de ld e, l ld d, h @@ -2104,7 +2104,7 @@ asm_cdbfa: ; cdbfa (33:5bfa) ld hl, BATTLEANIMSTRUCT_0F add hl, bc ld e, [hl] - ld hl, hPushOAM ; $ff80 + ld hl, hTransferVirtualOAM ; $ff80 add hl, de ld e, l ld d, h @@ -3332,7 +3332,7 @@ Functionce306: ; ce306 (33:6306) ld hl, BATTLEANIMSTRUCT_0F add hl, bc ld e, [hl] - ld hl, hPushOAM ; $ff80 + ld hl, hTransferVirtualOAM ; $ff80 add hl, de ld e, l ld d, h diff --git a/engine/routines/loadpushoam.asm b/engine/routines/loadpushoam.asm index 635152358..95f67ff73 100644 --- a/engine/routines/loadpushoam.asm +++ b/engine/routines/loadpushoam.asm @@ -1,5 +1,5 @@ -LoadPushOAM:: ; 4031 - ld c, hPushOAM - $ff00 +WriteOAMDMACodeToHRAM:: ; 4031 + ld c, hTransferVirtualOAM - $ff00 ld b, .PushOAMEnd - .PushOAM ld hl, .PushOAM .loop diff --git a/home/init.asm b/home/init.asm index 88ab0b58b..ec541ad16 100644 --- a/home/init.asm +++ b/home/init.asm @@ -103,10 +103,10 @@ Init:: ; 17d call ClearsScratch - ld a, BANK(LoadPushOAM) + ld a, BANK(WriteOAMDMACodeToHRAM) rst Bankswitch - call LoadPushOAM + call WriteOAMDMACodeToHRAM xor a ld [hMapAnims], a diff --git a/home/vblank.asm b/home/vblank.asm index d7a58cc1a..3b33b1ec5 100644 --- a/home/vblank.asm +++ b/home/vblank.asm @@ -113,7 +113,7 @@ VBlank0:: ; 2b1 ld a, [hOAMUpdate] and a jr nz, .done_oam - call hPushOAM + call hTransferVirtualOAM .done_oam @@ -192,7 +192,7 @@ VBlank1:: ; 337 call UpdateBGMap call Serve2bppRequest_VBlank - call hPushOAM + call hTransferVirtualOAM .done xor a @@ -282,7 +282,7 @@ VBlank3:: ; 396 call UpdateBGMap call Serve2bppRequest_VBlank - call hPushOAM + call hTransferVirtualOAM .done xor a @@ -338,7 +338,7 @@ VBlank4:: ; 3df call UpdateBGMap call Serve2bppRequest - call hPushOAM + call hTransferVirtualOAM call Joypad diff --git a/hram.asm b/hram.asm index 7810e5a01..d86fb3957 100644 --- a/hram.asm +++ b/hram.asm @@ -2,7 +2,7 @@ ; "ld a, [hAddress]" and "ld [hAddress], a" will ; use the more efficient "ldh" instruction. -hPushOAM EQU $ff80 ; 10 bytes +hTransferVirtualOAM EQU $ff80 ; 10 bytes hROMBankBackup EQU $ff8a hBuffer EQU $ff8b