new commands: modconnect, modconnectadmin & modlanconnect
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4391 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
@@ -43,6 +43,7 @@ void throttle()
|
||||
|
||||
string clientpassword = "";
|
||||
int connectrole = CR_DEFAULT;
|
||||
bool modprotocol = false;
|
||||
|
||||
void abortconnect()
|
||||
{
|
||||
@@ -116,17 +117,39 @@ void connectserv_(const char *servername, const char *serverport = NULL, const c
|
||||
|
||||
void connectserv(char *servername, char *serverport, char *password)
|
||||
{
|
||||
modprotocol = false;
|
||||
connectserv_(servername, serverport, password);
|
||||
}
|
||||
|
||||
void connectadmin(char *servername, char *serverport, char *password)
|
||||
{
|
||||
modprotocol = false;
|
||||
if(!password[0]) return;
|
||||
connectserv_(servername, serverport, password, CR_ADMIN);
|
||||
}
|
||||
|
||||
void lanconnect()
|
||||
{
|
||||
modprotocol = false;
|
||||
connectserv_(NULL);
|
||||
}
|
||||
|
||||
void modconnectserv(char *servername, char *serverport, char *password)
|
||||
{
|
||||
modprotocol = true;
|
||||
connectserv_(servername, serverport, password);
|
||||
}
|
||||
|
||||
void modconnectadmin(char *servername, char *serverport, char *password)
|
||||
{
|
||||
modprotocol = true;
|
||||
if(!password[0]) return;
|
||||
connectserv_(servername, serverport, password, CR_ADMIN);
|
||||
}
|
||||
|
||||
void modlanconnect()
|
||||
{
|
||||
modprotocol = true;
|
||||
connectserv_(NULL);
|
||||
}
|
||||
|
||||
@@ -217,6 +240,9 @@ COMMANDN(say, toserver, ARG_CONC);
|
||||
COMMANDN(connect, connectserv, ARG_3STR);
|
||||
COMMAND(connectadmin, ARG_3STR);
|
||||
COMMAND(lanconnect, ARG_NONE);
|
||||
COMMANDN(modconnect, modconnectserv, ARG_3STR);
|
||||
COMMAND(modconnectadmin, ARG_3STR);
|
||||
COMMAND(modlanconnect, ARG_NONE);
|
||||
COMMANDN(disconnect, trydisconnect, ARG_NONE);
|
||||
|
||||
void cleanupclient()
|
||||
|
||||
Reference in New Issue
Block a user