The Name Game: Difference between revisions

Content added Content deleted
m (→‎{{header|Z80 Assembly}}: improved readability of code)
Line 2,905: Line 2,905:
ld de,name3
ld de,name3
call PrintString_NameGame
call PrintString_NameGame

ret ;return to basic
ret ;return to basic
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 2,917: Line 2,918:
;else, just print what you see.
;else, just print what you see.
call &bb5a ;amstrad CPC kernel will print the contents of A as an ascii character
call &bb5a ;amstrad CPC kernel will print the contents of A as an ascii character



continue_NameGame:
continue_NameGame:
inc hl
inc hl
jr PrintString_NameGame
jr PrintString_NameGame
;;;;;;;;;;;;;;;; execution will never fall through this line without a jump

printNameAsIs:
printNameAsIs:
ex de,hl
ex de,hl
Line 2,930: Line 2,930:
ex de,hl
ex de,hl
jr continue_NameGame
jr continue_NameGame
;;;;;;;;;;;;;;;; execution will never fall through this line without a jump

insertName:
insertName:
push hl
push hl