new options for saved.cfg

Defaults to omitting variables from saved.cfg, that are still at default
value. By setting omitunchangeddefaults to zero, those variables get
written, but commented out. The variable "groupvariables" sets the number
of variables with similar names, that can be grouped on one line. Setting
it to zero will additionally write min, max and default values and a
short description of the variable to file.

In general, variables, that are still at default value, will not be
restored from saved.cfg, so when the default in the game is changed, all
clients will use that new default. This way, testers don't have to erase
their saved.cfg as often.

DOCREF omitunchangeddefaults groupvariables
This commit is contained in:
ac-stef
2015-03-06 14:01:52 +01:00
parent a013148305
commit 32db3e5e88
4 changed files with 26 additions and 4 deletions
+6
View File
@@ -165,6 +165,12 @@ COMMANDN(docref, adddocref, "ssss");
COMMANDN(docexample, adddocexample, "ss");
COMMANDN(dockey, adddockey, "sss");
const char *docgetdesc(const char *name)
{
docident *id = docidents.access(name);
return id ? id->desc : NULL;
}
char *cvecstr(vector<char *> &cvec, const char *substr, int *rline = NULL)
{
char *r = NULL;