Finally added allownq command.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2425 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2006-10-22 20:31:10 +00:00
parent 36c6537847
commit cdcbe7773c

View file

@ -602,6 +602,17 @@ char *Cmd_MaxViewers(cluster_t *cluster, sv_t *qtv, char *arg[MAX_ARGS], char *b
cluster->maxviewers = atoi(arg[1]); cluster->maxviewers = atoi(arg[1]);
return "maxviewers set\n"; return "maxviewers set\n";
} }
char *Cmd_AllowNQ(cluster_t *cluster, sv_t *qtv, char *arg[MAX_ARGS], char *buffer, int sizeofbuffer, qboolean localcommand)
{
if (!*arg[1])
{
buffer[0] = '\0';
snprintf(buffer, sizeofbuffer, "allownq is currently %i\n", cluster->allownqclients);
return buffer;
}
cluster->allownqclients = atoi(arg[1]);
return "allownq set\n";
}
char *Cmd_MaxProxies(cluster_t *cluster, sv_t *qtv, char *arg[MAX_ARGS], char *buffer, int sizeofbuffer, qboolean localcommand) char *Cmd_MaxProxies(cluster_t *cluster, sv_t *qtv, char *arg[MAX_ARGS], char *buffer, int sizeofbuffer, qboolean localcommand)
{ {
if (!*arg[1]) if (!*arg[1])
@ -750,7 +761,7 @@ char *Cmd_MVDPort(cluster_t *cluster, sv_t *qtv, char *arg[MAX_ARGS], char *buff
char *Cmd_Commands(cluster_t *cluster, sv_t *qtv, char *arg[MAX_ARGS], char *buffer, int sizeofbuffer, qboolean localcommand) char *Cmd_Commands(cluster_t *cluster, sv_t *qtv, char *arg[MAX_ARGS], char *buffer, int sizeofbuffer, qboolean localcommand)
{ {
return ""; return "fixme";
} }
typedef struct rconcommands_s { typedef struct rconcommands_s {
@ -791,6 +802,7 @@ const rconcommands_t rconcommands[] =
{"echo", 0, 1, Cmd_Echo}, {"echo", 0, 1, Cmd_Echo},
{"quit", 0, 1, Cmd_Quit}, {"quit", 0, 1, Cmd_Quit},
{"streams", 0, 1, Cmd_Streams}, {"streams", 0, 1, Cmd_Streams},
{"allownq", 0, 1, Cmd_AllowNQ},