Help Find map change system
#6

edit
i removed the other code because this is more simpler

pawn Код:
//add this at the top
new Cmaps;

//you only need the timer once !
//put it "OnPlayerConnect" or wherever you want! but if using it like OnPlayerSpawn you will need to kill the timer //so i will suggest you dont use it there.
SetTimerEx("NextMap", 20000, true, "i", 10);//not the number "10" at the end is for the maximum maps you will have !


forward NextMap(maps);
public NextMap(maps)
{
Cmaps++;
if(maps>= Cmaps) Cmaps=0;
switch(maps)
{
     case 0:{
          for(new playerid; playerid<GetMaxPlayers(); playerid++)//this will loop through all you players
          {
               SetPlayerPos(playerid,X,Y,Z);//this is the 1st MAP
          }
     }
     case 1:{
          for(new playerid; playerid<GetMaxPlayers(); playerid++)
          {
               SetPlayerPos(playerid,X,Y,Z);//this is the 2st MAP
          }
     case 2:{
          for(new playerid; playerid<GetMaxPlayers(); playerid++)
          {
               SetPlayerPos(playerid,X,Y,Z);//this is the 3st MAP
          }
//and you just continue like that..
     }
}
}
Reply


Messages In This Thread
Help Find map change system - by ServerScripter - 16.02.2012, 13:55
Re: Help Find map change system - by park4bmx - 16.02.2012, 14:19
Re: Help Find map change system - by ServerScripter - 16.02.2012, 14:23
Re: Help Find map change system - by park4bmx - 16.02.2012, 14:26
Re: Help Find map change system - by ServerScripter - 16.02.2012, 14:29
Re: Help Find map change system - by park4bmx - 16.02.2012, 14:36
Re: Help Find map change system - by Vince - 16.02.2012, 14:44
Re: Help Find map change system - by ServerScripter - 16.02.2012, 16:44
Re: Help Find map change system - by ServerScripter - 16.02.2012, 16:49
Re: Help Find map change system - by park4bmx - 16.02.2012, 16:54

Forum Jump:


Users browsing this thread: 8 Guest(s)