Skip to content

Commit

Permalink
Revert "Re-arrange some pointer load for aesthetics" that load into h
Browse files Browse the repository at this point in the history
  • Loading branch information
8bitZeta committed Jan 14, 2024
1 parent 39ab85a commit 5ea57b5
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion engine/battle/effect_commands.asm
Original file line number Diff line number Diff line change
Expand Up @@ -2808,8 +2808,8 @@ SpeciesItemBoost:
; it's holding item d, double it.

ld a, [hli]
ld h, a
ld l, [hl]
ld h, a
; fallthrough

DoubleStatIfSpeciesHoldingItem:
Expand Down
2 changes: 1 addition & 1 deletion engine/games/card_flip.asm
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,8 @@ _CardFlip:
.DeductCoins:
ld hl, wCoins
ld a, [hli]
ld h, a
ld l, [hl]
ld h, a
and a
jr nz, .deduct ; You have at least 256 coins.
ld a, l
Expand Down
2 changes: 1 addition & 1 deletion engine/link/link.asm
Original file line number Diff line number Diff line change
Expand Up @@ -2800,8 +2800,8 @@ Link_CheckCommunicationError:
vc_hook Wireless_prompt
ld hl, wLinkTimeoutFrames
ld a, [hli]
ld h, a
ld l, [hl]
ld h, a
push hl
call .CheckConnected
pop hl
Expand Down
2 changes: 1 addition & 1 deletion home/game_time.asm
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,8 @@ GameTimer::
; +1 hour
ld hl, wGameTimeHours
ld a, [hli]
ld h, a
ld l, [hl]
ld h, a
inc hl

; Cap the timer after 1000 hours.
Expand Down
6 changes: 3 additions & 3 deletions home/predef.asm
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@ Predef::
; Call the Predef function
ld hl, wPredefAddress
ld a, [hli]
ld h, a
ld l, [hl]
ld h, a
push hl

; Get hl back
ld hl, wPredefHL
ld a, [hli]
ld h, a
ld l, [hl]
ld h, a
ret

.Return:
Expand All @@ -47,6 +47,6 @@ Predef::

ld hl, wPredefHL
ld a, [hli]
ld h, a
ld l, [hl]
ld h, a
ret

0 comments on commit 5ea57b5

Please sign in to comment.