diff options
author | Rangi <35663410+Rangi42@users.noreply.github.com> | 2018-08-25 22:23:45 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-08-25 22:23:45 -0400 |
commit | 3eacab563d0e1ab5557c2443556a7a5e58d14cad (patch) | |
tree | 3d747166409fdc94f0fd1aa760693a7ee5bd2156 /engine/link/link_trade.asm | |
parent | 89681d231611938a791f4256e602c88c2f9aa3e1 (diff) | |
parent | b2adcd6d6ff91efc764a6ecc65147be7b9cda9e8 (diff) |
Merge pull request #555 from Rangi42/ldh
Use real labels for HRAM instead of constants, and the ldh instruction
Diffstat (limited to 'engine/link/link_trade.asm')
-rw-r--r-- | engine/link/link_trade.asm | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/engine/link/link_trade.asm b/engine/link/link_trade.asm index a250e84fa..95be2817a 100644 --- a/engine/link/link_trade.asm +++ b/engine/link/link_trade.asm @@ -185,10 +185,10 @@ LinkTradeMenu: .GetJoypad: push bc push af - ld a, [hJoyLast] + ldh a, [hJoyLast] and D_PAD ld b, a - ld a, [hJoyPressed] + ldh a, [hJoyPressed] and BUTTONS or b ld b, a @@ -201,11 +201,11 @@ LinkTradeMenu: .MenuAction: ld hl, w2DMenuFlags2 res 7, [hl] - ld a, [hBGMapMode] + ldh a, [hBGMapMode] push af call .loop pop af - ld [hBGMapMode], a + ldh [hBGMapMode], a ret .loop @@ -228,15 +228,15 @@ LinkTradeMenu: ret .UpdateBGMapAndOAM: - ld a, [hOAMUpdate] + ldh a, [hOAMUpdate] push af ld a, $1 - ld [hOAMUpdate], a + ldh [hOAMUpdate], a call WaitBGMap pop af - ld [hOAMUpdate], a + ldh [hOAMUpdate], a xor a - ld [hBGMapMode], a + ldh [hBGMapMode], a ret .loop2 |