Prev: 25369 Up: Map Next: 25556
25492: Print Character
Used by the routines at DescribeLocation, CollectWord, ListCarried and PrintFlag.
Plots A. A space that would sit on top of another space is rubbed out first. ENTER pads the row out to the margin.
PrintCharacter 25492 CP 32 A space may need to rub out a previous space.
25494 JR NZ,PrintCharacter_Other
25496 PUSH AF
25497 JR PrintCharacter_Rub
PrintCharacter_Other 25499 PUSH AF Only column 1 can be a doubled space.
25500 LD A,(23434)
25503 CP 1
25505 JR NZ,PrintCharacter_Keep
PrintCharacter_Rub 25507 LD A,(23452) The previous glyph is a space.
25510 CP 32
25512 JR NZ,PrintCharacter_Keep
25514 LD A,12 Rub it out.
25516 CALL PlotCharacter
PrintCharacter_Keep 25519 POP AF Remember this glyph.
25520 LD (23452),A
25523 PUSH AF Save the registers around the plot.
25524 PUSH HL
25525 PUSH BC
25526 PUSH DE
25527 CP 13 ENTER pads the line out to column 42.
25529 JR NZ,PrintCharacter_Plot
25531 LD A,(23434)
25534 LD B,A
PrintCharacter_Pad 25535 INC B One more column.
25536 LD A,43 Stop at column 42.
25538 CP B
25539 JR Z,PrintCharacter_Done
25541 LD A,32 Print a pad space and continue.
25543 CALL PlotCharacter
25546 JR PrintCharacter_Pad
PrintCharacter_Plot 25548 CALL PlotCharacter Call PlotCharacter to plot any other character.
This entry point is used by the routines at CollectWord, PrintObjectName and PrintNumberedMessage.
PrintCharacter_Done 25551 POP DE Restore the registers from the stack.
25552 POP BC
25553 POP HL
25554 POP AF
25555 RET Return.
Prev: 25369 Up: Map Next: 25556