How NetWars Works
The ideas inside NetWars 2.06, a 1993 networked 3-D space shooter for DOS, explained from the ground up. Read in order, the chapters should let you understand the game and build your own version of it, for example one that runs in a browser at a modern resolution.
- How to read this document: what NetWars is, what this text covers, evidence marks, words used throughout
- The game as a player sees it: screens, controls, goals, single and multiplayer
- The program as a loop: screens as states, what happens in one frame, how time is kept
- The world: space and numbers: coordinates, units, orientation, how directions and distances are stored
- Motion: flying the ship: steering, turning the axes, throttle and inertia, collision bumps, starts and restarts
- The objects of the world: fixed tables and limits, the body record, the life of an object, explosions, other players' copies
- Combat and collisions: laser hit boxes, missiles and the lock window, ramming, damage, "the shooter decides" in multiplayer
- Opponents and the rules of single player: alien kinds, shared steering, behaviours, pods, pick-ups, levels, score
- Multiplayer without a server: channels per slot, the lobby, the state packet, who decides what, keeping in step, coming and going, weak spots
- Drawing the 3-D world: the screen, models, projection, back-face culling, the painter's algorithm, stars and effects, with a live demo
- Sound: the PC speaker sequencer, the six effects (playable), when each plays
- Input and menus: key table and latches, mouse, every screen's keys, the menu bar, command line
- Bugs, quirks and secrets: what a player can use, what hurts, multiplayer bugs, what is hidden in the program
- Building it again: a browser version: what to keep, the parts of the program, multiplayer by invitation link without a game server, bugs to fix
- Appendices: where the data lives, constants, open questions