Resolve #428: Use HIGH(X)
and LOW(X)
instead of X / $100
and X % $100
or X >> 8
and X & $ff
This commit is contained in:
@@ -1241,10 +1241,10 @@ ScrollMapUp:: ; 2748
|
||||
ld h, a
|
||||
ld bc, $0200
|
||||
add hl, bc
|
||||
; cap d at VBGMap1 / $100
|
||||
; cap d at HIGH(VBGMap0)
|
||||
ld a, h
|
||||
and %00000011
|
||||
or VBGMap0 / $100
|
||||
or HIGH(VBGMap0)
|
||||
ld e, l
|
||||
ld d, a
|
||||
call UpdateBGMapRow
|
||||
@@ -1369,10 +1369,10 @@ UpdateBGMapColumn:: ; 27f8
|
||||
ld e, a
|
||||
jr nc, .skip
|
||||
inc d
|
||||
; cap d at VBGMap1 / $100
|
||||
; cap d at HIGH(VBGMap0)
|
||||
ld a, d
|
||||
and $3
|
||||
or VBGMap0 / $100
|
||||
or HIGH(VBGMap0)
|
||||
ld d, a
|
||||
|
||||
.skip
|
||||
|
Reference in New Issue
Block a user