diff options
Diffstat (limited to 'print.gbasm')
-rw-r--r-- | print.gbasm | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/print.gbasm b/print.gbasm new file mode 100644 index 0000000..e5bb898 --- /dev/null +++ b/print.gbasm @@ -0,0 +1,18 @@ +Print_8bit: ; Number in A, Memory Tilemap position in HL + PUSH AF + PUSH BC + + LD C, A + SWAP A ; We start by the highest nibble + AND $0f + OR $10 + LD (HL+), A + + LD A, C + AND $0f ; Then the lowest + OR $10 + LD (HL+), A + + POP BC + POP AF + RET |