forked from github/server
parent
268bccb69b
commit
e870de474e
|
@ -3279,7 +3279,7 @@ taxbuilding(const region * r)
|
||||||
if (!a) {
|
if (!a) {
|
||||||
int maxsize = buildingeffsize(b, false);
|
int maxsize = buildingeffsize(b, false);
|
||||||
double money = b->type->taxes(b, maxsize);
|
double money = b->type->taxes(b, maxsize);
|
||||||
if (money>0 && (best==NULL || money > maxmoney)) {
|
if (money>0 && (best==NULL || money > maxmoney || (money == maxmoney && b->size>best->size))) {
|
||||||
maxmoney = money;
|
maxmoney = money;
|
||||||
best = b;
|
best = b;
|
||||||
}
|
}
|
||||||
|
|
|
@ -169,7 +169,6 @@ static char * orders = NULL;
|
||||||
static int nowrite = 0;
|
static int nowrite = 0;
|
||||||
static boolean g_writemap = false;
|
static boolean g_writemap = false;
|
||||||
static boolean g_ignore_errors = false;
|
static boolean g_ignore_errors = false;
|
||||||
static boolean opt_reportonly = false;
|
|
||||||
static const char * luafile = NULL;
|
static const char * luafile = NULL;
|
||||||
static const char * preload = NULL;
|
static const char * preload = NULL;
|
||||||
static const char * script_path = "scripts";
|
static const char * script_path = "scripts";
|
||||||
|
@ -388,17 +387,16 @@ usage(const char * prog, const char * arg)
|
||||||
fprintf(stderr, "unknown argument: %s\n\n", arg);
|
fprintf(stderr, "unknown argument: %s\n\n", arg);
|
||||||
}
|
}
|
||||||
fprintf(stderr, "Usage: %s [options]\n"
|
fprintf(stderr, "Usage: %s [options]\n"
|
||||||
"-v befehlsdatei : verarbeitet automatisch die angegebene Befehlsdatei\n"
|
"-o befehlsdatei : verarbeitet automatisch die angegebene Befehlsdatei\n"
|
||||||
"-q : be less verbose\n"
|
"-q : be less verbose\n"
|
||||||
"-d datadir : gibt das datenverzeichnis an\n"
|
"-d datadir : gibt das datenverzeichnis an\n"
|
||||||
"-b basedir : gibt das basisverzeichnis an\n"
|
"-b basedir : gibt das basisverzeichnis an\n"
|
||||||
"-r resdir : gibt das resourceverzeichnis an\n"
|
"-r resdir : gibt das resourceverzeichnis an\n"
|
||||||
"-t turn : read this datafile, not the most current one\n"
|
"-t turn : read this datafile, not the most current one\n"
|
||||||
"-o reportdir : gibt das reportverzeichnis an\n"
|
"-R reportdir : gibt das reportverzeichnis an\n"
|
||||||
"-l path : specify the base script directory\n"
|
"-l path : specify the base script directory\n"
|
||||||
"-C : run in interactive mode\n"
|
"-C : run in interactive mode\n"
|
||||||
"-e script : main lua script\n"
|
"-e script : main lua script\n"
|
||||||
"-R : erstellt nur die Reports neu\n"
|
|
||||||
"--lomem : keine Messages (RAM sparen)\n"
|
"--lomem : keine Messages (RAM sparen)\n"
|
||||||
"--nobattle : keine Kämpfe\n"
|
"--nobattle : keine Kämpfe\n"
|
||||||
"--ignore-errors : ignore errors in scripts (please don\'t)\n"
|
"--ignore-errors : ignore errors in scripts (please don\'t)\n"
|
||||||
|
@ -478,7 +476,7 @@ read_args(int argc, char **argv, lua_State * luaState)
|
||||||
g_console = 1;
|
g_console = 1;
|
||||||
luafile=NULL;
|
luafile=NULL;
|
||||||
break;
|
break;
|
||||||
case 'o':
|
case 'R':
|
||||||
g_reportdir = argv[++i];
|
g_reportdir = argv[++i];
|
||||||
break;
|
break;
|
||||||
case 'e':
|
case 'e':
|
||||||
|
@ -504,13 +502,16 @@ read_args(int argc, char **argv, lua_State * luaState)
|
||||||
case 'q':
|
case 'q':
|
||||||
verbosity = 0;
|
verbosity = 0;
|
||||||
break;
|
break;
|
||||||
case 'v':
|
case 'o':
|
||||||
if (i<argc) {
|
if (i<argc) {
|
||||||
orders = argv[++i];
|
orders = argv[++i];
|
||||||
} else {
|
} else {
|
||||||
return usage(argv[0], argv[i]);
|
return usage(argv[0], argv[i]);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case 'v':
|
||||||
|
verbosity = atoi(argv[++i]);
|
||||||
|
break;
|
||||||
case 'p':
|
case 'p':
|
||||||
loadplane = atoi(argv[++i]);
|
loadplane = atoi(argv[++i]);
|
||||||
break;
|
break;
|
||||||
|
@ -536,9 +537,6 @@ read_args(int argc, char **argv, lua_State * luaState)
|
||||||
case 'w':
|
case 'w':
|
||||||
g_writemap = true;
|
g_writemap = true;
|
||||||
break;
|
break;
|
||||||
case 'R':
|
|
||||||
opt_reportonly = true;
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
usage(argv[0], argv[i]);
|
usage(argv[0], argv[i]);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue