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
Tested and work
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