@done:
ret
- ; puts strings as objects
- ; inputs:
- ; hl: the string
- ; b/c: y/x origin
- ; de: starting object
-objputs:
- ; write y
- ld a, b
- add a, OBJ_OFF_Y
- ld [de], a
- inc de
-
- ; write x
- ld a, c
- add a, OBJ_OFF_X
- ld [de], a
- inc de
-
- ; move to next tile
- ld c, a
-
- ; write letter
- ld a, [hl+]; also advance to next letter
- add a, FONT_OFFSET ; need to move to different bank
- ld [de], a
- inc de
-
- xor a, a
- ld [de], a
- inc de
-
- ; exit check
- ld a, [hl]
- cp a, 0
- jr nz, objputs REL
-
-@done:
- ret