- Notifications
You must be signed in to change notification settings - Fork163
An FPS/RTS hybrid game powered by the Daemon engine (a combination of ioq3 and XreaL)
License
Unvanquished/Unvanquished
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Unvanquished is an arena game with RTS elements (you can build) in which two very different factions fight.
Windows | macOS | Linux |
---|---|---|
ℹ️ We provide ready-to-use downloads for the Unvanquished game on thedownload page.
ℹ️ This repository contains the source code for the game logic of Unvanquished.
💡️ If you only want to play the game or run a server and want to rebuild, you only need to build theDæmon engine anddownload the game's assets.
💡️ You need to build this repository if you want to contribute to the game logic or make a mod with custom game logic binaries.
See below forbuild andlaunch instructions.
The Unvanquished game is translated on theWeblate platform, this is the easier way to contribute translations since it offers a central place where people can contribute and review translations while reducing risks of merge conflicts. Weblate preserves authorship and automatically produces commits that can be associated with your GitHub account.
To fetch and build Unvanquished, you'll need:git
,cmake
,python
≥ 2,python-yaml
,python-jinja
,and a C++14 compiler. The following are actively supported:gcc
≥ 9,clang
≥ 11,Visual Studio/MSVC (at least Visual Studio 2019).
Required:zlib
,libgmp
,libnettle
,libcurl
,SDL2
,GLEW
,libpng
,libjpeg
≥ 8,libwebp
≥ 0.2.0,Freetype
,Lua
,OpenAL
,libogg
,libvorbis
,libopus
,libopusfile
.
Optional:ncurses
.
MSYS2 is the recommended way to build using MinGW on a Windows host.
Required packages for 64-bit:mingw-w64-x86_64-gcc
,mingw-w64-x86_64-cmake
,make
Required packages for 32-bit:mingw-w64-i686-gcc
,mingw-w64-i686-cmake
,make
Seethe wiki for more detailed instructions.
Unvanquished requires several sub-repositories to be fetched before compilation. If you have not yet cloned this repository:
git clone --recurse-submodules https://github.com/Unvanquished/Unvanquished.git
If you have already cloned:
cd Unvanquished/git submodule update --init --recursive
ℹ️ If cmake complains about missing files indaemon/
folder or similar issue then you have skipped this step.
If you don't have the assets, you can download them first. You can download an universal zip from thedownload page, here is thelink to the latest version.Thepkg/
folder can be stored in thehomepath.
Otherwise you can use the package downloader script. This script can usearia2c
,curl
orwget
.aria2c
is recommended.
You can do./download-paks --help
for more options.
./download-paks build/pkg
The above snippet places thepkg
directory in thelibpath of the Daemon engine that you are building,so it will only be automatically found from this build directory. If you prefer the paks to befound by from all installations/build directories, consider downloading to thepkg/
subdirectoryof thehomepath.
ℹ️ This will build both the game engine and the game logic. Building both makes things more convenient for testing and debugging.
💡️ Instead of-j4
you can use-jN
whereN
is your number of CPU cores to distribute compilation on them. Linux systems usually provide a handynproc
tool that tells the number of CPU core so you can just do-j$(nproc)
to use all available cores.
Enter the directory before anything else:
cd Unvanquished/
- Run CMake.
- Choose your compiler.
- Open
Unvanquished.sln
and compile.
Produced files will be stored in a new directory namedbuild
.
mkdir build;cd buildcmake ..make -j4
mkdir build;cd buildcmake .. -G"MSYS Makefiles"make -j4
💡️ For a 32-bit build use thecross-toolchain-mingw32.cmake
toolchain file instead.
mkdir build-win64;cd build-win64cmake .. -DCMAKE_TOOLCHAIN_FILE=../daemon/cmake/cross-toolchain-mingw64.cmakemake -j4
ℹ️ On Windows you'll have to usedaemon.exe
anddaemonded.exe
instead of./daemon
and./daemonded
, everything else will be the same.
First, enter thebuild/
folder:
cd build
Assuming thepkg/
folder is stored next to thedaemon
binary:
./daemon
You can also use-pakpath
to load assets from apkg/
folder stored somewhere else,<PATH>
stands for the path to thepkg/
folder.
./daemon -pakpath<PATH>
If you want to run a server, you may prefer to use the non-graphicaldaemonded
server binary instead ofdaemon
and start the first map (here,plat23 is used as an example) from the command line.
Assuming thepkg/
folder is stored next to thedaemonded
binary:
./daemonded +map plat23
You can use-pakpath
to load assets from apkg/
folder stored somewhere else (see above).
You may want to copy and extend someconfiguration samples, they must be stored in your user home directory, for details see thegame locations wiki page and the page aboutrunning a server.
ℹ️ This is not a tutorial to distribute a modified game usable by players. See the wiki for modbuildingandhostingtutorials.
ℹ️ This is not needed to run the released game or a server.
As a developer, you may want to run the game logic as a shared library and load modified assets from thepkg/unvanquished_src.dpkdir
submodule.
Assuming you already have a releasepkg/
folder, you can do it this way:
./daemon -pakpath ../pkg -set vm.sgame.type 3 -set vm.cgame.type 3
Note that only the basicunvanquished_src.dpkdir
asset package is provided that way, and running Unvanquished only with that package will bring you some warnings about other missing packages and you will miss soundtrack and stuff like that.
ℹ️ If you are looking for the sources of the whole assets, have a look at theUnvanquishedAssets repository. Beware that unlike theunvanquished_src.dpkdir
package most of them can't be loaded correctly by the engine without being built first.
Please don't commit submodules in pull requests, as the submodule references may not exist after the pull requests are rebased and merged.
When a feature is split across more than one repository, submodules are expected to be committed after each pull requests has been merged.
ℹ️ More details can be found in the wiki:wiki:Dealing with submodules.
About
An FPS/RTS hybrid game powered by the Daemon engine (a combination of ioq3 and XreaL)