mirror of
https://github.com/thornAvery/jep-hack.git
synced 2026-02-21 06:58:45 +13:00
First Commit
Upload literally everything from the pokecrystal16 expand-move-ID branch
This commit is contained in:
commit
2f8a41f833
4618 changed files with 480386 additions and 0 deletions
35
home/compare.asm
Normal file
35
home/compare.asm
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
CompareBytes::
|
||||
; Compare c bytes at de and hl.
|
||||
; Return z if they all match.
|
||||
.loop
|
||||
ld a, [de]
|
||||
cp [hl]
|
||||
ret nz
|
||||
inc de
|
||||
inc hl
|
||||
dec c
|
||||
jr nz, .loop
|
||||
ret
|
||||
|
||||
CompareBytesLong::
|
||||
; Compare bc bytes at de and hl.
|
||||
; Return carry if they all match.
|
||||
.loop
|
||||
ld a, [de]
|
||||
cp [hl]
|
||||
jr nz, .diff
|
||||
|
||||
inc de
|
||||
inc hl
|
||||
dec bc
|
||||
|
||||
ld a, b
|
||||
or c
|
||||
jr nz, .loop
|
||||
|
||||
scf
|
||||
ret
|
||||
|
||||
.diff:
|
||||
and a
|
||||
ret
|
||||
Loading…
Add table
Add a link
Reference in a new issue