Twirl Demo is an impressive display of a spinning cyclonic column ... like looking at the surface of a tornado. It is by Revival Studios, which has several newer (2012-2014) 16K games for the ZX81, even featuring Internet High Scores(?) ... by Martijn Wenting of the Netherlands. These are "killer games" for the ZX81
V I D E O: ZX81 16k: "Twirl" Demo This TWIRL demo contains a lot of ASCII text, not too surprising if this is a port from another platform. But what is the ASCII to ZX Text routine?
MACHINE CODE IN REM STATEMENT
-----------------------------
Uses a standard technique of machine code in REM 1
Code: Select all
1 REM REVIVAL COPY CLEAR 5 RNDLN STR$ RNDLN $INKEY$ GOSUB s
* first, using 7E to hide 5 bytes
Code: Select all
db ZX_NUMBER ;$7E (126) hide the next 5 bytes
JP $4092
NOP
NOP
Code: Select all
1 REM REVIVAL
* Finally, uses 76h to hide the rest
Code: Select all
dbzx 'REVIVAL'
db ZX_NEWLINE ;76h (118)
CHARACTERS STRINGS USED
-----------------------
Strings identified using HexDump option of ZXLister
68B2h NO HIGHSCORE CODE
5034h *** TWIRL DEMO, BY REVIVAL STUDIOS *** (C)2010 ***
41DCh to 46AFh WELCOME TO THIS LITTLE TWIRL DEMO ... [1235 bytes of text]
ALTERNATE DISPLAY FILE
----------------------
Also seen in HexDump: an Alternate Display File at 46C2h, which looks like it contains all the initial visual data
ASCII TO ZX81
-------------
ASCII to ZX81 routine
Code: Select all
ASCII 'A' = 65 (41h)
ZX81 'A' = 38 (26h)
--------------------
27 (1Bh)
$6CD4 which appear to be a ZX to ASCII routine
$6D74 which is the ASCII to ZX81 routine, tested in the assembly file attached
The ZX to ASCII routine uses a table lookup for the punctuation characters. Interestingly it adopts a convention of mapping the apostrophe (which ZX81 does not have) to CHR 1 (the Northwest_Block character)