• Unfortunately, we have experienced significant hard drive damage that requires urgent maintenance and rebuilding. The forum will be a state of read only until we install our new drives and rebuild all the configurations needed. Please follow our Facebook page for updates, we will be back up shortly! (The forum could go offline at any given time due to the nature of the failed drives whilst awaiting the upgrades.) When you see an Incapsula error, you know we are in the process of migration.

/gmlist Command {By CrAshInSiDe}

Experienced Elementalist
Joined
Jun 29, 2006
Messages
255
Reaction score
0
Its a mod of who2,its useful for user when in a server the command /who2 its only for GM
This command show all GM online
Code:
[b][u]In gmcmds.cpp find[/b][/u]
        Log( MSG_GMACTION, " %s : /tele %i,%i,%i" , thisclient->CharInfo->charname, map, x, y);     
        return pakGMTele(thisclient, map, x, y);
    }
[b][u]After Add[/b][/u]
/* GM List {By CrAshInSiDe} */
 else if(strcmp(command, "gmlist")==0) 
    {
        if(Config.Command_GmList > thisclient->Session->accesslevel)
            return true;       
        SendPM(thisclient, "The currently GM connected is:");
        int count=1;
        int hiddenam=0;
        char line0[200];
        while(count <= (ClientList.size()-1)) 
        {
            CPlayer* whoclient = (CPlayer*)ClientList.at(count)->player;
            if(whoclient->Session->accesslevel > 100) 
            {
                sprintf(line0, "%s - GM[%i]", whoclient->CharInfo->charname, whoclient->Session->accesslevel);                                      
            } 
 
            if(whoclient->isInvisibleMode != true) 
            {
                SendPM(thisclient, line0 );
            } 
            else 
            {
                hiddenam++;
            }
            count++;
        }
        sprintf(line0, "There are currently %i GM connected!", ((ClientList.size()-1)-hiddenam));
        Log( MSG_GMACTION, " %s : /gmlist" , thisclient->CharInfo->charname);
        SendPM(thisclient, line0 );
        return true;
    }
[b][u]In sockets.h find[/b][/u]
    int Command_Go;
    int Command_Who;
    int Command_Who2;  
[b][u]After add[/b][/u]
    int Command_GmList; 
[b][u]In worldserver.cpp find[/b][/u]
    Config.Command_IQuest = ConfigGetInt    ( "commands.ini", "iquest", 299 );
    Config.Command_Item = ConfigGetInt    ( "commands.ini", "item", 299 );
[b][u]After Add[/b][/u]
    Config.Command_GmList = ConfigGetInt ( "commands.ini", "gmlist", 299 );
[b][u]In commands.ini find[/b][/u]
Give2=299
GiveFairy=299
GiveZuly=299
[b][u]After Add[/b][/u]
GmList=99
Tested and work :D
 
Newbie Spellweaver
Joined
Apr 3, 2009
Messages
14
Reaction score
0
Sorry for bump -.-
but error on socket..

Code:
In file included from ../Common/SocketBase.cpp:21:
../Common/sockets.h:327: error: declaration of `int CROSEServerConfig::Command_GmList'
../Common/sockets.h:253: error: conflicts with previous declaration `int CROSEServerConfig::Command_GmList'

make.exe: *** [../Common/SocketBase.o] Error 1

Execution terminated
 
Back
Top