02.11.2013, 16:07
HEY everyone , Before I had a map change , but I added the same stuffs in Public onPlayerSpawn(For players who just connected to the server) & Public onMapChange(For players who are already playing) so it's done two times & make the gm huge....
Now, I have some ideas how to make a simple map change without taking a lot of space in my GM :
1-There is a timer in OnGameModeInt for the Map change
2-
everything is fine , but in a map change we must expect two things :
-the players who are already in the server .
-The player who just joined the server .
-The problem is I don't wanna repeat things two times , as u know we set teams/weapons... for already players & who just joined the server , so I decided to call a function like :
Public OnFirstMap()
{
}
but I can't add stuff like Kick(playerid) it says "playerid indifined"
I just ask how to make it easier , a map change that does its role one time , not two times...
Now, I have some ideas how to make a simple map change without taking a lot of space in my GM :
1-There is a timer in OnGameModeInt for the Map change
pawn Код:
SetTimer("MapChange",1000,true);
pawn Код:
forward MapChange();
public MapChange()
{
SecondesMap ++;
if(SecondesMap == 1)
{
print(" First gm");
}
else if(SecondesMap == 3)
{
print(" Secon MAP !!");
}
else if(SecondesMap == 6)
{
print(" Secon MAP !!");
SecondesMap=0;
}
}
-the players who are already in the server .
-The player who just joined the server .
-The problem is I don't wanna repeat things two times , as u know we set teams/weapons... for already players & who just joined the server , so I decided to call a function like :
Public OnFirstMap()
{
}
but I can't add stuff like Kick(playerid) it says "playerid indifined"
I just ask how to make it easier , a map change that does its role one time , not two times...