diff --git a/binaries/system/readme.txt b/binaries/system/readme.txt index 4aa596207e..54346f585a 100644 --- a/binaries/system/readme.txt +++ b/binaries/system/readme.txt @@ -39,6 +39,7 @@ Configuration: -yres=N set screen Y resolution to 'N' Advanced / diagnostic: +-version print the version of the engine and exit -dumpSchema creates a file entity.rng in the working directory, containing complete entity XML schema, used by various analysis tools -entgraph (disabled) diff --git a/source/main.cpp b/source/main.cpp index 3e3adf6439..add12cbc3a 100644 --- a/source/main.cpp +++ b/source/main.cpp @@ -1,4 +1,4 @@ -/* Copyright (C) 2015 Wildfire Games. +/* Copyright (C) 2016 Wildfire Games. * This file is part of 0 A.D. * * 0 A.D. is free software: you can redistribute it and/or modify @@ -416,6 +416,12 @@ static void RunGameOrAtlas(int argc, const char* argv[]) g_args = args; + if (args.Has("version") || args.Has("-version")) + { + debug_printf("Pyrogenesis %s\n", engine_version); + return; + } + // We need to initialise libxml2 in the main thread before // any thread uses it. So initialise it here before we // might run Atlas.