diff options
| author | Daniel Harding <33dannye@gmail.com> | 2020-05-20 20:17:30 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-05-20 20:17:30 -0500 |
| commit | 500d99c258145d233af8d14cdb5c6e0200dfc1d8 (patch) | |
| tree | 7dbe7b152dde8a6e9b56664b5b8cdfc0d6be1253 /home/copy2.asm | |
| parent | Merge pull request #39 from TiKevin83/master (diff) | |
| parent | Merge remote-tracking branch 'pokered/master' (diff) | |
| download | pokeyellow-500d99c258145d233af8d14cdb5c6e0200dfc1d8.tar.gz pokeyellow-500d99c258145d233af8d14cdb5c6e0200dfc1d8.tar.xz pokeyellow-500d99c258145d233af8d14cdb5c6e0200dfc1d8.zip | |
Merge pull request #50 from dannye/master
merge pokered
Diffstat (limited to 'home/copy2.asm')
| -rw-r--r-- | home/copy2.asm | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/home/copy2.asm b/home/copy2.asm index ad47c4a0..c14112bb 100644 --- a/home/copy2.asm +++ b/home/copy2.asm @@ -1,30 +1,30 @@ FarCopyDataDouble:: ; Expand bc bytes of 1bpp image data ; from a:de to 2bpp data at hl. - ld [wFarCopyDataSavedROMBank],a - ld a,[H_LOADEDROMBANK] + ld [wFarCopyDataSavedROMBank], a + ld a, [H_LOADEDROMBANK] push af - ld a,[wFarCopyDataSavedROMBank] + ld a, [wFarCopyDataSavedROMBank] call BankswitchCommon - ld a,h ; swap hl and de - ld h,d - ld d,a - ld a,l - ld l,e - ld e,a - ld a,b + ld a, h ; swap hl and de + ld h, d + ld d, a + ld a, l + ld l, e + ld e, a + ld a, b and a - jr z,.eightbitcopyamount - ld a,c + jr z, .eightbitcopyamount + ld a, c and a ; multiple of $100 jr z, .expandloop ; if so, do not increment b because the first instance of dec c results in underflow .eightbitcopyamount inc b .expandloop - ld a,[de] + ld a, [de] inc de - ld [hli],a - ld [hli],a + ld [hli], a + ld [hli], a dec c jr nz, .expandloop dec b |
