fox32rom: Add %x support to draw_format_str
This commit is contained in:
parent
16399b2f27
commit
0c889859de
|
@ -139,6 +139,10 @@ draw_format_str_generic_found_format_specifier:
|
||||||
cmp.8 [r0], 'u'
|
cmp.8 [r0], 'u'
|
||||||
ifz call draw_format_str_generic_unsigned_decimal
|
ifz call draw_format_str_generic_unsigned_decimal
|
||||||
|
|
||||||
|
; hex
|
||||||
|
cmp.8 [r0], 'x'
|
||||||
|
ifz call draw_format_str_generic_hex
|
||||||
|
|
||||||
inc r0
|
inc r0
|
||||||
jmp draw_format_str_generic_loop
|
jmp draw_format_str_generic_loop
|
||||||
draw_format_str_generic_percent_sign:
|
draw_format_str_generic_percent_sign:
|
||||||
|
@ -166,6 +170,14 @@ draw_format_str_generic_unsigned_decimal:
|
||||||
pop r0
|
pop r0
|
||||||
inc r16
|
inc r16
|
||||||
ret
|
ret
|
||||||
|
draw_format_str_generic_hex:
|
||||||
|
call draw_format_str_generic_get_parameter
|
||||||
|
push r0
|
||||||
|
mov r0, r17
|
||||||
|
call draw_hex_generic
|
||||||
|
pop r0
|
||||||
|
inc r16
|
||||||
|
ret
|
||||||
draw_format_str_generic_get_parameter:
|
draw_format_str_generic_get_parameter:
|
||||||
; load the correct format parameter into r17
|
; load the correct format parameter into r17
|
||||||
; this is messy, but i don't know of any other way to do this at the moment
|
; this is messy, but i don't know of any other way to do this at the moment
|
||||||
|
|
Loading…
Reference in New Issue
Block a user