Where to put the code??? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Where to put the code??? (
/showthread.php?tid=601964)
Where to put the code??? -
professional killer - 29.02.2016
I have made this code which checks to see that their should be atleast 1 zombie player. I just can't figure out where to put this code :P
EDIT: I only want to check once after the map starts that if zombie team is empty.
Код:
if((playerOnline >= 1) && (GetTeamPlayersAlive(TEAM_ZOMBIE) == 0))
{
new rand = -1;
while(!IsPlayerConnected(rand)) rand = random(MAX_PLAYERS);
ZombieSetup(rand);
SpawnPlayer(rand);
}
Re: Where to put the code??? -
Amunra - 29.02.2016
What Your Mean ?
I Think Your Mean "Where the CODE Put", Right ?
if Right You Can Put at :
Re: Where to put the code??? -
professional killer - 29.02.2016
no dude if i put it in onplayerspawn it will check number of zombie everytime a player connects. I said i just want to check it once after a map begins.