diff options
author | libjet <libj3t@gmail.com> | 2020-02-19 02:47:03 +0000 |
---|---|---|
committer | libjet <libj3t@gmail.com> | 2020-02-19 02:47:03 +0000 |
commit | 0a0b273fee50a66baeac441600254d77af442bef (patch) | |
tree | f09717414d9cb45496340819a423f1f5adada69e | |
parent | 5172056acdf4691e8d3db4563d3a1a73d7025efc (diff) |
Add home/queue_script.asm
-rwxr-xr-x | engine/specials.asm | 4 | ||||
-rw-r--r-- | home.asm | 15 | ||||
-rwxr-xr-x | home/queue_script.asm | 12 | ||||
-rw-r--r-- | wram.asm | 4 |
4 files changed, 21 insertions, 14 deletions
diff --git a/engine/specials.asm b/engine/specials.asm index c6ccef66..c12198bf 100755 --- a/engine/specials.asm +++ b/engine/specials.asm @@ -342,9 +342,9 @@ DummyNonfunctionalGameCornerGame: ; c4e7 (3:44e7) ret Functionc4f4: ; c4f4 (3:44f4) - call Function3425 + call FarQueueScript call FadeToMenu - ld hl, wcfd8 + ld hl, wQueuedScriptBank ld a, [hli] push af ld a, [hli] @@ -194,29 +194,24 @@ SkipNames:: INCLUDE "home/math.asm" INCLUDE "home/print_text.asm" -Function3414:: +CallPointerAt:: ldh a, [hROMBank] push af ld a, [hli] rst Bankswitch + ld a, [hli] ld h, [hl] ld l, a + call _hl_ + pop hl ld a, h rst Bankswitch ret -QueueScript:: - ldh a, [hROMBank] -Function3425:: - ld [wcfd8], a - ld a, l - ld [wcfd9], a - ld a, h - ld [wcfda], a - ret +INCLUDE "home/queue_script.asm" Function3431:: .asm_3431 diff --git a/home/queue_script.asm b/home/queue_script.asm new file mode 100755 index 00000000..23f80d24 --- /dev/null +++ b/home/queue_script.asm @@ -0,0 +1,12 @@ +QueueScript:: +; Push pointer hl in the current bank to wQueuedScriptBank. + ldh a, [hROMBank] + +FarQueueScript:: +; Push pointer a:hl to wQueuedScriptBank. + ld [wQueuedScriptBank], a + ld a, l + ld [wQueuedScriptAddr], a + ld a, h + ld [wQueuedScriptAddr + 1], a + ret
\ No newline at end of file @@ -2424,8 +2424,8 @@ wcfd4:: ds 1 ; cfd4 wcfd5:: ds 1 ; cfd5 wcfd6:: ds 1 ; cfd6 wcfd7:: ds 1 ; cfd7 -wcfd8:: ds 1 ; cfd8 -wcfd9:: ds 1 ; cfd9 +wQueuedScriptBank:: ds 1 ; cfd8 +wQueuedScriptAddr:: ds 1 ; cfd9 wcfda:: ds 1 ; cfda wPredefID:: ds 1 ; cfdb wPredefTemp:: dw ; cfdc |