Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
889efa7
Archival commit, works well enough to almost print the title screen o…
venomix666 Dec 25, 2025
567ac4e
It now makes it to West of house...
venomix666 Dec 25, 2025
8cbd3dc
Gets a bit longer, but get_sibling does not decode correctly
venomix666 Dec 25, 2025
8c876f9
It doesnt crash anymore, but it cant read the input correctly and pri…
venomix666 Dec 25, 2025
12a936c
Archival commit, debugging input parsing
venomix666 Dec 25, 2025
8104b32
Fixed z-string decoding
venomix666 Jan 2, 2026
313713e
Dictionary lookup seems to work
venomix666 Jan 2, 2026
6a72fc3
Now also prints strings at addresses above 0xffff. PC etc. also needs…
venomix666 Jan 2, 2026
2d997d2
Fixed ZSCII escape printing
venomix666 Jan 2, 2026
3427b49
Archival commit, full of debugging trace prints
venomix666 Jan 6, 2026
7ed40c7
Multiple fixes, now prints Zork I intro correctly
venomix666 Jan 7, 2026
20f9c3a
czech.z3 now runs without crashing, but many tests fail
venomix666 Jan 7, 2026
d60f4c3
Now passes all czech-tests! Needs massive cleanup
venomix666 Jan 9, 2026
1fe61a4
Some cleanup
venomix666 Jan 9, 2026
531a442
Multiple small fixes. Zork I is now semi-playable!
venomix666 Jan 9, 2026
fbe8f9a
Zork I now runs on actual CP/M-65! But not great...
venomix666 Jan 9, 2026
f37cf62
Merge branch 'davidgiven:master' into z65
venomix666 Jan 9, 2026
0cb3e4a
Added defines for header data locations
venomix666 Jan 10, 2026
2182381
Fixed various bugs, Zork I now seems fully playable but Mini-Zork can…
venomix666 Jan 11, 2026
8bf59ce
Fixed bug where variables were treaded as 8 bit in some opcodes. Mini…
venomix666 Jan 11, 2026
860d2cb
Some bugfixes. Zork I and Minizork plays without issue not and czech …
venomix666 Jan 12, 2026
98a6636
Avoid clearing the parse buffer in case games give illegal lengths...
venomix666 Jan 13, 2026
0590d2c
Added save functionality, no load yet
venomix666 Jan 13, 2026
7665d01
Save/Restore implemented and almost working, crashes on first command…
venomix666 Jan 15, 2026
89e26b2
Saving and loading seems to work! Needs massive cleanup
venomix666 Jan 20, 2026
cf734d6
Cleaned up debug tracing
venomix666 Jan 20, 2026
2854a81
More cleanup of tracing code
venomix666 Jan 20, 2026
6bf9743
Formatting
venomix666 Jan 20, 2026
1140c53
Updates to reduce binary size
venomix666 Jan 22, 2026
2f7322f
Dynamic allocation of memory using zmalloc. Fixed formatting
venomix666 Jan 22, 2026
d2bb797
Fixed backspace check to inlude 127. Removed a bunch of old commented…
venomix666 Jan 22, 2026
90d720e
Added header, cleaned up comments
venomix666 Jan 22, 2026
2ec94e5
Fixed so that carriage return is also printed with newline
venomix666 Jan 22, 2026
78f20fa
Added freeware 10k adventure Moonglow
venomix666 Jan 22, 2026
970402a
Added to build files for all systems where it fits on the disk
venomix666 Jan 22, 2026
345eabc
Removed some stray newlines
venomix666 Jan 22, 2026
52fcce6
Added some info about z65 to the readme
venomix666 Jan 22, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -622,6 +622,17 @@ END OF FILE
OK
```

### The Z-machine interpreter

z65 is Z-machine interpeter for version 3 Z-machine adventures, written from scratch for CP/M-65. The freeware adventure moonglow is supplied with it to have something to run, but is has been tested with many of the classic version 3 Infocom games (Zork I-III, Mini-Zork, Planetfall, Hollywood Hijinx etc.). It has however not been extensively tested and almost certainly has a lot of bugs, so please report any issues you find.

Saving and restoring games is supported if the games implement support for it. No check is made to ensure that the file being restored is for the correct game.

Usage: Run it with the game file you want to run as a command line argument:
```
A> Z65 MOONGLOW.Z3
```

### Utilities

`bin/cpmemu` contains a basic CP/M-65 user mode emulator and debugger. It'll run
Expand Down
5 changes: 5 additions & 0 deletions config.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,11 @@
"0:triangle.frt": "cpmfs+triangle_frt_cpm",
}

Z65_APPS = {
"0:z65.com": "third_party/z65",
"0:moonglow.z3": "third_party/z65/moonglow.z3",
}

SERIAL_APPS = {
"0:xrecv.com": "apps+xrecv",
"0:xsend.com": "apps+xsend",
Expand Down
3 changes: 2 additions & 1 deletion src/arch/apple2e/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
BIG_SCREEN_APPS,
PASCAL_APPS,
FORTH_APPS,
Z65_APPS,
)

llvmcfile(
Expand Down Expand Up @@ -73,7 +74,7 @@
bootimage=".+bios_shuffled",
size=143360,
items={} | SCREEN_APPS | SCREEN_APPS_SRCS | BIG_SCREEN_APPS | PASCAL_APPS
| FORTH_APPS,
| FORTH_APPS | Z65_APPS,
)


Expand Down
7 changes: 5 additions & 2 deletions src/arch/atari800/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
BIG_SCREEN_APPS,
PASCAL_APPS,
FORTH_APPS,
Z65_APPS,
)

llvmclibrary(name="headers", hdrs={"atari800.inc": "./atari800.inc"})
Expand Down Expand Up @@ -122,7 +123,8 @@
| SCREEN_APPS_SRCS
| BIG_SCREEN_APPS
| PASCAL_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

simplerule(
Expand Down Expand Up @@ -172,7 +174,8 @@
| SCREEN_APPS_SRCS
| BIG_SCREEN_APPS
| PASCAL_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

simplerule(
Expand Down
10 changes: 7 additions & 3 deletions src/arch/kim-1/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
BIG_SCREEN_APPS,
PASCAL_APPS,
FORTH_APPS,
Z65_APPS,
)

COMMODORE_ITEMS = (
Expand Down Expand Up @@ -128,7 +129,8 @@
| SCREEN_APPS
| BIG_SCREEN_APPS
| PASCAL_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

mkcpmfs(
Expand All @@ -149,7 +151,8 @@
| SCREEN_APPS
| BIG_SCREEN_APPS
| PASCAL_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

mkcpmfs(
Expand All @@ -173,7 +176,8 @@
| SCREEN_APPS
| BIG_SCREEN_APPS
| PASCAL_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

mkimd(name="diskimage-k1013", src=".+rawdiskimage-k1013")
Expand Down
4 changes: 3 additions & 1 deletion src/arch/nano6502/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
SERIAL_APPS,
SERIAL_SCREEN_APPS,
FORTH_APPS,
Z65_APPS,
)

llvmrawprogram(
Expand Down Expand Up @@ -40,7 +41,8 @@
| PASCAL_APPS
| SERIAL_APPS
| SERIAL_SCREEN_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

mkcpmfs(
Expand Down
2 changes: 2 additions & 0 deletions src/arch/neo6502/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
BIG_SCREEN_APPS,
PASCAL_APPS,
FORTH_APPS,
Z65_APPS,
)
import re

Expand Down Expand Up @@ -80,6 +81,7 @@
| BIG_SCREEN_APPS
| PASCAL_APPS
| FORTH_APPS
| Z65_APPS
).items()
},
)
4 changes: 3 additions & 1 deletion src/arch/oric/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
BIG_SCREEN_APPS,
PASCAL_APPS,
FORTH_APPS,
Z65_APPS,
)

llvmcfile(
Expand Down Expand Up @@ -55,7 +56,8 @@
| SCREEN_APPS_SRCS
| BIG_SCREEN_APPS
| PASCAL_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

mkoricdsk(name="diskimage", src=".+cpmfs")
Expand Down
10 changes: 7 additions & 3 deletions src/arch/osi/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
BIG_SCREEN_APPS,
PASCAL_APPS,
FORTH_APPS,
Z65_APPS,
)

# ----------------------------------------------------------------------------
Expand Down Expand Up @@ -207,7 +208,8 @@
| PASCAL_APPS
| MINIMAL_APPS_SRCS
| BIG_APPS_SRCS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

mkcpmfs(
Expand Down Expand Up @@ -246,7 +248,8 @@
| PASCAL_APPS
| MINIMAL_APPS_SRCS
| BIG_APPS_SRCS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

mkcpmfs(name="osif-b_rawdiskimage", format="osi8", size=128 * 1848, items={})
Expand Down Expand Up @@ -358,7 +361,8 @@
| BIG_APPS_SRCS
| SCREEN_APPS_SRCS
| BIG_SCREEN_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

mkcpmfs(
Expand Down
4 changes: 3 additions & 1 deletion src/arch/snes/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
BIG_SCREEN_APPS,
PASCAL_APPS,
FORTH_APPS,
Z65_APPS,
)

llvmrawprogram(
Expand Down Expand Up @@ -38,7 +39,8 @@
| SCREEN_APPS
| BIG_SCREEN_APPS
| PASCAL_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

simplerule(
Expand Down
4 changes: 3 additions & 1 deletion src/arch/sorbus/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
PASCAL_APPS,
SERIAL_APPS,
FORTH_APPS,
Z65_APPS,
)

llvmrawprogram(
Expand All @@ -29,7 +30,8 @@
| BIG_APPS_SRCS
| PASCAL_APPS
| SERIAL_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

zip(
Expand Down
4 changes: 3 additions & 1 deletion src/arch/x16/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
BIG_APPS_SRCS,
PASCAL_APPS,
FORTH_APPS,
Z65_APPS,
)

llvmrawprogram(
Expand All @@ -27,7 +28,8 @@
| BIG_APPS
| BIG_APPS_SRCS
| PASCAL_APPS
| FORTH_APPS,
| FORTH_APPS
| Z65_APPS,
)

zip(
Expand Down
10 changes: 10 additions & 0 deletions third_party/z65/build.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
from build.ab import Rule, Target, Targets, simplerule
from build.llvm import llvmprogram
from tools.build import unixtocpm

llvmprogram(
name="z65",
cflags=["-Ithird_party/zmalloc"],
srcs=["./z65.c"],
deps=["lib+cpm65", "third_party/zmalloc+zmalloc"],
)
Binary file added third_party/z65/moonglow.z3
Binary file not shown.
Loading