summaryrefslogtreecommitdiff
path: root/home/battle.asm
diff options
context:
space:
mode:
authorlibjet <libj3t@gmail.com>2020-03-15 00:17:02 +0000
committerlibjet <libj3t@gmail.com>2020-03-15 00:17:02 +0000
commit76216e6ce5de8a78cfd9312eb08dbb127b4d34d0 (patch)
treedaa241c9541bd7f66aea7220cd4da5efb9a8069a /home/battle.asm
parent1ddf04da73b8784a08c679b73f576923768f97cf (diff)
Small home/ reorganization
Diffstat (limited to 'home/battle.asm')
-rw-r--r--home/battle.asm19
1 files changed, 19 insertions, 0 deletions
diff --git a/home/battle.asm b/home/battle.asm
index a7f7a558..eac378e0 100644
--- a/home/battle.asm
+++ b/home/battle.asm
@@ -258,3 +258,22 @@ GetBattleAnimByte::
pop hl
ld a, [wca17]
ret
+
+PushLYOverrides::
+ ldh a, [hLCDCPointer]
+ and a
+ ret z
+
+ ld a, LOW(wLYOverridesBackup)
+ ld [wRequested2bppSource], a
+ ld a, HIGH(wLYOverridesBackup)
+ ld [wRequested2bppSource + 1], a
+
+ ld a, LOW(wLYOverrides)
+ ld [wRequested2bppDest], a
+ ld a, HIGH(wLYOverrides)
+ ld [wRequested2bppDest + 1], a
+
+ ld a, (wLYOverridesEnd - wLYOverrides) / 28
+ ld [wRequested2bpp], a
+ ret