You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+34-20Lines changed: 34 additions & 20 deletions
Original file line number
Diff line number
Diff line change
@@ -1,14 +1,15 @@
1
1
# The Lighthouse of Doom
2
2
3
3
This repository contain a simple text-based adventure game, implemented
4
-
twice, once in portable C, and once in Z80 assembly language, targetted
5
-
at the CP/M operating system.
4
+
twice, once in portable C, and once in Z80 assembly language, available
5
+
for both the CP/M operating system and the humble 48k ZX Spectrum.
6
6
7
7
My intention was to write a simple text-based adventure game to run under
8
8
CP/M. Starting large projects in Z80 assembly language from scratch
9
9
is a bit of a daunting prospect, so I decided to code the game in C first,
10
10
so that I could get the design right, and avoid getting stuck in too many
11
-
low-level details initially.
11
+
low-level details initially. Later I ported to the Spectrum, because
12
+
it seemed like a fun challenge for myself!
12
13
13
14
Quick links within this README file:
14
15
@@ -17,8 +18,8 @@ Quick links within this README file:
17
18
*[Building & running it](#building--running-it)
18
19
*[Z80 Implementation](#z80-implementation)
19
20
*[Z80 Changes](#z80-changes)
20
-
*[Compiling & running it](#compiling--running-it)
21
-
*[Downloading It](#downloading-it)
21
+
*[Compiling & running it](#compiling--running-it)
22
+
*[Downloading It](#downloading-it)
22
23
*[Bugs?](#bugs)
23
24
24
25
@@ -78,37 +79,50 @@ The implementation uses a simple set of structures:
78
79
* An item-table to store details about each object in the game.
79
80
* A person table to store telephone messages.
80
81
81
-
The whole implementation is defined in the file [game.z80](game.z80).
82
+
The main implementation can be found in the file [game.z80](game.z80),
83
+
but because we support two targets (CP/M 2.x and the ZX Spectrum) there
84
+
is a small amount of platform-specific code found in [bios.z80](bios.z80).
82
85
83
-
Along the way I did realize that having fixed inventory slots made the
84
-
coding more of a challenge, so I made the location of each object a
85
-
property of the object itself.
86
+
The `Makefile` should build everything appropriately for both systems,
87
+
defining `SPECTRUM`, and `ENTRYPOINT` as appropriate.
86
88
87
89
88
90
### Z80 Changes
89
91
92
+
* Along the way I realized that having fixed inventory slots made the coding more of a challenge, so I made the location of each object a property of the object itself.
90
93
* The Z80 version has more easter-eggs (Try typing "`xyzzy`" a few times).
91
94
* There are __two__ victory conditions.
92
-
* The Z80 version can be built with the text-strings, and game code, protected by simple XOR encryption
95
+
* The CP/M version of the game can be built with the text-strings, and game code, protected by simple XOR encryption:
93
96
* This stops users from looking through the binary for hints.
94
-
* Run `make release` to build the _protected_ version.
95
-
* Run `make game` to build a raw version.
97
+
* Run `make release` to build the _protected_CP/M version.
98
+
* Run `make game-cpm` to build a raw CP/M version.
96
99
97
100
98
-
###Compiling & Running It
101
+
## Compiling & Running It
99
102
100
-
Ensure you have the `pasmo` assembler installed, then build the code
101
-
by running `make game`, or `make release`.
103
+
Ensure you have the `pasmo` assembler installed, and then use the supplied Makefile to compile the game.
102
104
103
-
In either case the output will be a binary named `lihouse.com` which you
104
-
should be able to run upon your system - or under a CP/M emulator.
105
+
Running `make` will generate the default targets:
105
106
107
+
*`make lighthouse` -> Build the game for linux.
108
+
*`make lihouse.com` -> Build the game for CP/M, without the XOR encryption.
109
+
*`make lihouse.tap` -> Build the game for the 48k ZX Spectrum.
106
110
107
-
### Downloading It
111
+
If you wish to build only individual things then :
112
+
113
+
*`make game-cpm` to build a normal CP/M version.
114
+
*`make game-spectrum` to build the ZX Spectrum version.
115
+
*`make lighthouse` will build the C-game for Linux
116
+
*`make release` will build the _protected_ CP/M version.
117
+
118
+
119
+
120
+
## Downloading It
108
121
109
122
If you look on our [release page](https://github.com/skx/lighthouse-of-doom/releases/) you can find the latest stable build.
110
123
111
-
Transfer `lihouse.com` to your system, and run `LIHOUSE` to launch it.
124
+
* For CP/M download `lihouse.com` to your system, and then run `LIHOUSE` to launch it.
125
+
* For the ZX Spectrum download `lihouse.tap` to your system, and then launch in your favourite emulator.
112
126
113
127
114
128
## Bugs?
@@ -118,7 +132,7 @@ Report any bugs as you see them:
118
132
* A crash of the game is a bug.
119
133
* Bad spelling, grammar, or broken punctuation are also bugs.
120
134
* Getting into a zombie-state where winning or losing are impossible is a bug.
0 commit comments