nuclide-lite/BUILDING

112 lines
3.3 KiB
Text

# Building Manual
## Introduction
The Makefile (tested with GNU Make) contains an assortment of targets
that will make building of assets and code into the game easier.
Here we will discuss the various targets mentioned, you can build
any of them at any time (dependencies should resolve themselves)
using the usual `make` syntax:
make _target_ GAME=id1
Where `_target_` is to be substituted with a valid target. The `GAME=`
override decides which game directory to consider using.
Generally, you want to make a copy of either `id1`, `qw` or `data1`,
name it something original (say `foobar`) and then you would pass
`GAME=foobar` instead of `GAME=id1`.
If the GAME variable isn't passed, `id1` is assumed.
## Targets
### help
Will display some short help information on important targets that
are available. Also the default result when no target is specified.
### all
Build all of the code, models, maps, textures and 2D graphics for a
given game. You probably want to run this sparingly (or on the first time).
### wad
Builds all texture wads for a given game. The textures are to
be placed within a sub-directory within your game's `texturesrc/`
directory. Each directory gets compiled into its own WAD. If you
want to target WAD3, simply place an empty file named `WAD3` within
the desired directory.
### maps
Builds all the maps (and texture wads) for a given game.
### GAME/maps/mapname.bsp
Will compile GAME/maps/mapname.bsp. So if you were to run
`make id1/maps/start.bsp`, that would be valid - as long as
`id1/mapsrc/start.map` was to exist.
### models
Builds all models for a given game using FTEQW's iqmtool.
### defs
Builds an entities.def file for use in QED/Radiant and integrates
it into the editors that are present in the local installation.
Currently it will also build all available editors, but that will
probably change.
### gfx
Builds all the 2D graphics (menu related, mainly) for a given game.
### palette
Rebuilds the palette for the given game. Reads from
GAME/gfxsrc/palette.png and will ensure to build a new palette.lmp for
use in the engine, as well as a colormap.lmp for software renderers
as well as a palette.pal for use in WorldCraft based editors.
You will probably want to rebuild all your other assets after this.
### update
Updates tools + game repos.
### radiant
Builds GtkRadiant and gives it with a launcher: ./radiant
### netradiant-custom
Builds NetRadiant-Custom, a popular alternative to the upstream
GtkRadiant. You can use this to update + rebuild a new version.
Will also place a launcher in your game directory: ./netradiant-custom
### launcher
Builds a launcher for your game using FTEQW. Will accept command-line arguments
and will execute a config file with your username if present. This way
developers can stay out of each others way, even on a non-versioned
filesystem. This is for development purposes only.
### pak
Will build pak0.pak and pak1.pak files (shareware and registered
archives) for your game. Ensure you use the right Precache_* APIs so
the tool knows which data belongs to shareware and which to registered
versions of your game.
## Legal advice regarding pop.lmp
Do not ship Quake's gfx/pop.lmp. Vanilla engines will look for it, but
forks/source-ports will not. Feel free to compile your own proof-of-purchase
check in your own custom engine.