[HOW TO]Spawn All?
#8

Quote:
Originally Posted by SpiderPork
In my opinion, you should check if the player, which you will be spawning, is online, like this:

pawn Код:
forward SpawnAll();
public SpawnAll()
{
   for(new i = 0; i < MAX_PLAYERS; i++)
   {
     if(IsPlayerConnected(i))
     {
        SpawnPlayer(i);
     }
   }
}
Doesn't have to be, using if(IsPlayerConnected(i)) would take longer to do the loop, and since you cannot spawn a not-connected playerid you don't have to worry.
Reply


Messages In This Thread
[HOW TO]Spawn All? - by CaLaP - 23.08.2009, 12:03
Re: [HOW TO]Spawn All? - by Correlli - 23.08.2009, 12:04
Re: [HOW TO]Spawn All? - by CaLaP - 23.08.2009, 12:26
Re: [HOW TO]Spawn All? - by ronyx69 - 23.08.2009, 12:29
Re: [HOW TO]Spawn All? - by Frankylez - 23.08.2009, 12:38
Re: [HOW TO]Spawn All? - by CaLaP - 23.08.2009, 13:30
Re: [HOW TO]Spawn All? - by SpiderPork - 23.08.2009, 13:37
Re: [HOW TO]Spawn All? - by Andom - 23.08.2009, 13:39

Forum Jump:


Users browsing this thread: 1 Guest(s)