mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2024-11-16 11:27:33 -08:00
Spaces to tabs.
This commit is contained in:
parent
45083625ee
commit
28e223d988
14
main.asm
14
main.asm
@ -27,19 +27,19 @@ CopyBytes: ; 0x3026
|
|||||||
SwapBytes: ; 0x3034
|
SwapBytes: ; 0x3034
|
||||||
; swap bc bytes between hl and de
|
; swap bc bytes between hl and de
|
||||||
.Loop
|
.Loop
|
||||||
; stash [hl] away on the stack
|
; stash [hl] away on the stack
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
push af
|
push af
|
||||||
|
|
||||||
; copy a byte from [de] to [hl]
|
; copy a byte from [de] to [hl]
|
||||||
ld a, [de]
|
ld a, [de]
|
||||||
ld [hli], a
|
ld [hli], a
|
||||||
|
|
||||||
; retrieve the previous value of [hl]; put it in [de]
|
; retrieve the previous value of [hl]; put it in [de]
|
||||||
pop af
|
pop af
|
||||||
ld [de], a
|
ld [de], a
|
||||||
|
|
||||||
; handle loop stuff
|
; handle loop stuff
|
||||||
inc de
|
inc de
|
||||||
dec bc
|
dec bc
|
||||||
ld a, b
|
ld a, b
|
||||||
@ -84,19 +84,19 @@ GetFarByte: ; 0x304d
|
|||||||
|
|
||||||
GetFarHalfword: ; 0x305d
|
GetFarHalfword: ; 0x305d
|
||||||
; retrieve a halfword from a:hl, and return it in hl.
|
; retrieve a halfword from a:hl, and return it in hl.
|
||||||
; bankswitch to new bank
|
; bankswitch to new bank
|
||||||
ld [$ff00+$8b], a
|
ld [$ff00+$8b], a
|
||||||
ld a, [$ff00+$9d]
|
ld a, [$ff00+$9d]
|
||||||
push af
|
push af
|
||||||
ld a, [$ff00+$8b]
|
ld a, [$ff00+$8b]
|
||||||
rst $10
|
rst $10
|
||||||
|
|
||||||
; get halfword from new bank, put it in hl
|
; get halfword from new bank, put it in hl
|
||||||
ld a, [hli]
|
ld a, [hli]
|
||||||
ld h, [hl]
|
ld h, [hl]
|
||||||
ld l, a
|
ld l, a
|
||||||
|
|
||||||
; bankswitch to previous bank and return
|
; bankswitch to previous bank and return
|
||||||
pop af
|
pop af
|
||||||
rst $10
|
rst $10
|
||||||
ret
|
ret
|
||||||
|
Loading…
x
Reference in New Issue
Block a user