| Tools - AdvSkelVic65 | |
| |
| Notes | Text adventure code for cc65 and the Vic20, C16, PET, C64 and Atari 8-bit targets. Very efficient! The main executable of the Vic20 version is ~1.71k, the c16 version is ~1.28k and the PET version 1.99k. These figures were taken without text compression and as disk support. Includes Windows batch files to compile the program. CBM disk versions require cbmconvert, and Atari disks use Dir2Atr.
The Vic20 binary version requires 16k memory expansion, but the cartridge versions use an unexpanded memory setup.
The C64 version now supports disks and single files. The Vic20 and C16 versions also now support single-file binaries. Support is provided for Atari 800 disks.
The Atari 8-bit cartridge format works up to 32k now. The 32k version is a bank-switched MegaCart cartridge.
[Benefits]
* Very efficient, as I used my CBMSimpleIO and AtaSimpleIO libraries, lots of inline assembler, global and zeropage variables, function parameters in global and zeropage variables, numbers to identify verbs and nouns, the Cubbyhole optimization technique that uses a computer's Low memory when otherwise unused during a cc65 program, optimizations to the crt0.s files by excluding unneeded code in them and other optimizations, most of which can be found online at https://sourceforge.net/projects/cc65extra/files/. * Supports limited compression of text: uses tokenization and RLE of spaces. * Easy-to-use: provided you know what you're doing, it should be easy to adapt this code to a specific text adventure. * This program supports the Commodore PET, the Vic20, the C16, the C64 and the Atari 800 and C16, C64 and Atari8 cartridges. All but the Vic20 cartridge versions support 32k cartridges. * Customizability: you can change the prompt and add things such as colors and new verbs and nouns to the code. * Memory: this code supports systems with little memory and has ways to maximize usable memory. * This code has ways to target each supported system with codes that take adventage of each system's abilities and otherwise make the code more efficient.
[Drawbacks]
* You currently can't swap rooms from disk: all rooms have to fit in memory. * Compression is limited and requires manual compression. * Doesn't include ANSI support, as it would waste a lot of space, so support for other machines has to be written in the code. * Other text adventure creators probably support more platforms.
[New]
* Heavy optimizations and cleaning up of code
[Known Bug]
* Text compression on PET targets doesn't work properly: tokens expand to garbage.
[Planned]
* Small Apple2 support * Better compression * One-part Atari8 and PET binaries * Expandibility of used zeropage space on CBM targets * The ability to add more directions * Optimizations to save game support * Support for more control characters when not compressing text * Updates to AdvSkel65, including save game support and some bug-fixes to some 128k versions
This is to update the last version of AdvSkelVic65 with some bug fixes. The following are the bugs that this is supposed to fix:
* The PET target was displaying garbage when printing compressed strings. This bug was caused by not switching the character definitions as needed by PrintTok, the mechanism that prints compressed strings. This is needed because, otherwise, capital letters would be inter- preted as tokens. * When printing valid exits from a room and using text compression, on the PET target, the exits, which use upper-case, print the wrong symbol. I needed to switch to the regular PETSCII key assignments just for them. * When targeting 32k cartridges and using text compression, some messages stored in the main bank were not printed properly. This is caused by using a function that prints from the auxilliary bank instead of one that prints from the main bank. This was solved but at the cost that such messages can't be compressed. PrintTok has a version that can support both main memory and auxilliary memory, but that version is not used here. * The disk-based C16 target occasionally crashed. This was caused by using the Cubbyhole optimization technique and having one extra block overwrite two bytes needed by the kernal to display to the screen.
To install these bug fixes, simply extract these files to their own folder and replace the .c files in the original distrbution with the same names as these with these.
The documentation also neglected to mention that the first room as included in the code showed an example of how to use PrintTok to display compressed strings. It shows how to tokenize repeated text snippets. For more information, read the printtok-002.c file included in the main distribution. |
| |
Copyright © Plus/4 World Team, 2001-2024. Support Plus/4 World on Patreon |