Table of Contents
Warzone 2100 is written in C++ and uses the SDL (input and graphics context), OpenGL (graphics), OpenAL (sound) and PhysicsFS (filesystem) libraries.
Development activity is quite distributed, we have a mailing list at Gna.org, bug tracker on http://developer.wz2100.net, and an IRC channel on freenode, #warzone2100-dev. That channel is only for development-related discussion, to talk about other things (problems with the game...) use #warzone2100.
For instructions on how to compile the game, and other coding documentation, see the following links:
Directory structure
The source is structure as follows:
| Directory | Description |
| / | The root directory, containing build scripts mostly |
| /src | The main source code directory |
| /lib | Additional code factored into multiple separate parts |
| /lib/framework | Basic code and types used everywhere else |
| /lib/gamelib | todo: add gamelib information here |
| /lib/ivis02 | Software renderer, was removed long ago |
| /lib/ivis_common | Common code between all renderers |
| /lib/ivis_opengl | The OpenGL graphics renderer |
| /lib/netplay | Network code |
| /lib/script | Much of the scripting logic resides here |
| /lib/sequence | Code to show game videos (currently doesn't do much) |
| /lib/sound | Sound code |
| /lib/widget | Widget (basic UI) code |
| /m4 | m4 files belonging to the GNU build toolchain |
| /data | All the data files we can legally distribute |
| /win32 | MSVC project files and icons |
| /autopackage | Support files for building AutoPackages |
| /makerules | Support files for the Makefile.raw build |
| /debian | Support files for building Debian packages |
If you want to get a feel of how Warzone works, you may want to start looking at src/main.cpp. Command line parsing is done in src/clparse.cpp, and key mappings are in src/keymap.cpp. Autogenerated Doxygen docs of master are at http://buildbot.wz2100.net/files/doxygen/ (not well maintained though at the moment). Enjoy!
Network
The network code had a major overhaul.
Todo
See the Todo list. Warzone is a complete and mature game, but it still has great potential for improvement.
Release check-list
Naming Conventions
- Project: Warzone 2100 Project
- Title case
- Product: Warzone 2100
- With a capital 'W'
- Binary executable: warzone2100
- All lowercase and no whitespace
Repository Structure or: What Goes Where
(If you don't know some of the terms used here, or how to actually handle branches, merges etc., see the links on Git Howto)
We have three main branches:
- 3.1 is the current release branch, which only receives bugfixes and necessary maintenance commits. Especially after the release of 3.1.0, no commit here should break compatibility of the config folder (maps, mods, savegames...)
- master, where development for the next release happens
- bugfixes, where commits for both master and 3.1 go, this is merged periodically into master and 3.1.
All those should always compile and work reasonably well, especially the release branch (that and master are autobuilt by the buildbot). For work that would destabilize master too much or delay the next release, using a separate branch is strongly suggested. The bugfixes branch was introduced so that a commit always can be referred to by one hash, regardless of the branch it is in.
