more logging; allow assembly of vote permission string

git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4036 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
ac_stef
2008-12-18 14:49:36 +00:00
parent 544aaea0a4
commit d09b11068b
2 changed files with 13 additions and 4 deletions
+3 -2
View File
@@ -566,7 +566,8 @@ int main(int argc, char **argv)
bool dedicated = false;
int uprate = 0, maxcl = DEFAULTCLIENTS, kthreshold = -5, bthreshold = -6, port = 0, permdemo = -1;
const char *sdesc = "", *sdesc_pre = "", *sdesc_suf = "", *ip = "", *master = NULL, *passwd = "", *maprot = NULL, *adminpwd = NULL, *pwdfile = NULL, *blfile = NULL, *srvmsg = NULL, *voteperms = NULL, *demop = NULL;
const char *sdesc = "", *sdesc_pre = "", *sdesc_suf = "", *ip = "", *master = NULL, *passwd = "", *maprot = NULL, *adminpwd = NULL, *pwdfile = NULL, *blfile = NULL, *srvmsg = NULL, *demop = NULL;
static string voteperms; voteperms[0] = '\0';
pushscontext(IEXC_CFG);
@@ -630,7 +631,7 @@ int main(int argc, char **argv)
case 'y': bthreshold = atoi(a); break;
case 'f': port = atoi(a); break;
case 'D': permdemo = isdigit(*a) ? atoi(a) : 0; break;
case 'P': voteperms = *a ? a : NULL; break;
case 'P': s_strcat(voteperms, a); break;
case 'W': demop = a; break;
default: conoutf("unknown commandline option");
}
+10 -2
View File
@@ -3594,6 +3594,13 @@ void initserver(bool dedicated, int uprate, const char *sdesc, const char *sdesc
if(permdemo > 0) maxdemos = permdemo;
if(verbose) logger->writeline(log::info, "recording demo of every game (holding up to %d in memory)", maxdemos);
}
if(verbose)
{
if(demopath[0]) logger->writeline(log::info,"all recorded demos will be written to: \"%s\"", demopath);
if(voteperm[0]) logger->writeline(log::info,"vote permission string: \"%s\"", voteperm);
logger->writeline(log::info,"server description: \"%s\"", servdesc_full);
if(servdesc_pre[0] || servdesc_suf[0]) logger->writeline(log::info,"custom server description: \"%sCUSTOMPART%s\"", servdesc_pre, servdesc_suf);
}
}
resetserverifempty();
@@ -3636,7 +3643,8 @@ int main(int argc, char **argv)
#endif
int uprate = 0, maxcl = DEFAULTCLIENTS, kthreshold = -5, bthreshold = -6, port = 0, permdemo = -1;
const char *sdesc = "", *sdesc_pre = "", *sdesc_suf = "", *ip = "", *master = NULL, *passwd = "", *maprot = "", *admpwd = NULL, *pwdfile = NULL, *blfile = NULL, *srvmsg = NULL, *service = NULL, *voteperms = NULL, *demop = NULL;
const char *sdesc = "", *sdesc_pre = "", *sdesc_suf = "", *ip = "", *master = NULL, *passwd = "", *maprot = "", *admpwd = NULL, *pwdfile = NULL, *blfile = NULL, *srvmsg = NULL, *service = NULL, *demop = NULL;
static string voteperms; voteperms[0] = '\0';
for(int i = 1; i<argc; i++)
{
@@ -3673,7 +3681,7 @@ int main(int argc, char **argv)
case 'S': service = a; break;
case 'f': port = atoi(a); break;
case 'D': permdemo = isdigit(*a) ? atoi(a) : 0; break;
case 'P': voteperms = *a ? a : NULL; break;
case 'P': s_strcat(voteperms, a); break;
case 'W': demop = a; break;
default: printf("WARNING: unknown commandline option\n");
}