mirror of
https://github.com/thornAvery/kep-hack.git
synced 2026-02-06 15:45:24 +13:00
Use HIGH() and LOW()
This commit is contained in:
parent
bbc257476f
commit
45ed05decf
22 changed files with 89 additions and 87 deletions
|
|
@ -12,10 +12,10 @@ AddItemToInventory_::
|
|||
push hl
|
||||
push hl
|
||||
ld d, PC_ITEM_CAPACITY ; how many items the PC can hold
|
||||
ld a, wNumBagItems & $FF
|
||||
ld a, LOW(wNumBagItems)
|
||||
cp l
|
||||
jr nz, .checkIfInventoryFull
|
||||
ld a, wNumBagItems >> 8
|
||||
ld a, HIGH(wNumBagItems)
|
||||
cp h
|
||||
jr nz, .checkIfInventoryFull
|
||||
; if the destination is the bag
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue