ZX Spectrum Font Modification: Italic and Bold Italic / Word Dictionary for Text Adventures
Italic Letters for the Printer
The program modifies italic letters in two ways. It is ideal for hackers whose printers do not have this option, but others can use it too, since the letters look better than the Spectrum’s ROM characters. You can use italics or bold italics.
For the first method, remove the RRA instruction at the BOLD label. For the second, enter the entire listing. The program is written in machine code for Gens.
ORG 50000
CALL RAZV
LD HL,49000
LD BC,96
CHRS PUSH BC
LD B,3
LOOP LD A,(HL)
SRA A
LD (HL),A
INC HL
DJNZ LOOP
LD B,2
LOPP INC HL
DJNZ LOPP
LD B,3
LLOP LD A,(HL)
SLA A
LD (HL),A
INC HL
DJNZ LLOP
POP BC
DEC BC
LD A,B
OR C
JR NZ,CHRS
RET
RAZV LD HL,15616
LD DE,49000
PUSH DE
LD BC,768
PETL LD A,(HL)
BOLD RRA
OR (HL)
LD (DE),A
INC HL
INC DE
DEC BC
LD A,B
OR C
JR NZ,PETL
POP DE
DEC D
LD (23606),DE
RET
Bold Letters
This short program lets you print messages in BASIC in bold letters.
10 FOR N=50000 TO 50027:
READ A:POKE N,A:NEXT N
20 RANDOMIZE USR 50000
30 DATA 17,0,252,213,33,0
Adventure Dictionary
Since most people do not buy original games, they also do not have the instructions for adventures containing a dictionary of all the words the program understands. The easiest way is to list the program in CHR$ code. First, prevent the program from starting automatically. Then enter:
10 FOR N=65000 TO 65023:
READ A:POKE N,A:NEXT N
DATA 33,168,97,126,254
A similar program in machine code is much faster:
ORG 65000
LD HL,25000
LL LD A,(HL)
CP 32
JRC LOOP
CP 128
JR NC,LOOP
RST 16
LOOP INC HL
LD DE,65000
PUSH HL
SBC HL,DE
POP HL
JRC ,LL
RET
In this section, ZX Revija has decided to present the preceding programs in this issue, which will probably help many readers. These interesting programs were taken from older issues of Mog Mikra and were written by various authors.
Share your thoughts about the article