mirror of
https://github.com/StewBC/mminer-apple2.git
synced 2024-06-26 04:29:28 +00:00
Text drawing works with modified font
This commit is contained in:
parent
565f343bdd
commit
dfa049472d
|
@ -31,6 +31,8 @@ read:
|
||||||
lda PLACEHOLDER, x ; get the character in the string
|
lda PLACEHOLDER, x ; get the character in the string
|
||||||
sec
|
sec
|
||||||
sbc #32 ; the font only starts at space (char 32 or $20)
|
sbc #32 ; the font only starts at space (char 32 or $20)
|
||||||
|
beq :+
|
||||||
|
sbc #9 ; gap after space
|
||||||
asl ; mult by 16 as that's how wide a char is in bytes
|
asl ; mult by 16 as that's how wide a char is in bytes
|
||||||
asl
|
asl
|
||||||
rol fontH
|
rol fontH
|
||||||
|
@ -38,6 +40,7 @@ read:
|
||||||
rol fontH
|
rol fontH
|
||||||
asl
|
asl
|
||||||
rol fontH ; srcPtr now points at the char but $0000 based
|
rol fontH ; srcPtr now points at the char but $0000 based
|
||||||
|
:
|
||||||
adc #<font ; add the font start
|
adc #<font ; add the font start
|
||||||
sta fontL
|
sta fontL
|
||||||
lda fontH
|
lda fontH
|
||||||
|
@ -177,6 +180,8 @@ read:
|
||||||
lda PLACEHOLDER, x ; get the character in the string
|
lda PLACEHOLDER, x ; get the character in the string
|
||||||
sec
|
sec
|
||||||
sbc #32 ; the font only starts at space (char 32 or $20)
|
sbc #32 ; the font only starts at space (char 32 or $20)
|
||||||
|
beq :+ ; gap after space
|
||||||
|
sbc #9
|
||||||
asl ; mult by 16 as that's how wide a char is in bytes
|
asl ; mult by 16 as that's how wide a char is in bytes
|
||||||
asl
|
asl
|
||||||
rol srcPtrH
|
rol srcPtrH
|
||||||
|
@ -184,6 +189,7 @@ read:
|
||||||
rol srcPtrH
|
rol srcPtrH
|
||||||
asl
|
asl
|
||||||
rol srcPtrH ; srcPtr now points at the char but $0000 based
|
rol srcPtrH ; srcPtr now points at the char but $0000 based
|
||||||
|
:
|
||||||
adc #<font ; add the font start
|
adc #<font ; add the font start
|
||||||
sta srcPtrL
|
sta srcPtrL
|
||||||
lda srcPtrH
|
lda srcPtrH
|
||||||
|
|
Loading…
Reference in New Issue
Block a user