17.03.2013, 23:23
Quote:
yes
pawn Код:
|
Also your just setting the world to 69, what if he has around 30 players online, all do /dm. the first 9 will get to world 0 but the rest 21 will go to world 69.
pawn Код:
new playersdm=0;
new DM[MAX_PLAYERS];
command:dm ( playerid, params[])
{
playersdm++;
DM[playerid] = 1;
if(playersdm>9) SetPlayerVirtualWorld(playerid, 69); DM[playerid] = 1;
//do other stuff here(teleport/etc..)
return 1;
}
command: exitdm() {
playersdm--;
DM[playerid] = 0;
SetPlayerVirtualWorld(playerid, 0);
}
OnPlayerDisconnect
{
if(DM[playerid] == 1) playersdm--;
}
OnPlayerDeath
{
if(DM[playerid] == 1) playersdm--;
}