I'm currently working on a project for school in x86 assembly. We are coding the retro game Breakout.
We render the game in video mode 13h. The problem is that we would like to display the current score of the player on the screen. This is a procedure we have for printing a $-terminated string to the screen:
PROC displayString
    ARG @@row:DWORD, @@column:DWORD, @@offset:DWORD
    USES EAX, EBX, EDX
    MOV EDX, [@@row] ; row in EDX
    MOV EBX, [@@column] ; column in EBX
    MOV AH, 02H ; set cursor position
    SHL EDX, 08H ; row in DH (00H is top)
    MOV DL, BL ; column in DL (00H is left)
    MOV BH, 0 ; page number in BH
    INT 10H ; raise interrupt
    MOV AH, 09H ; write string to standard output
    MOV EDX, [@@offset] ; offset of '$'-terminated string in EDX
    INT 21H ; raise interrupt
    RET
ENDP displayString
The problem is that I can't find a solid way to convert our integer into a dollar terminated string so that this procedure can print it on the screen.
Can anyone offer suggestions on how to convert a value to a $ terminated string?
 
    