Random ID for Squad`s problem - 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: Random ID for Squad`s problem (
/showthread.php?tid=536886)
Random ID for Squad`s problem -
Sanady - 12.09.2014
Hello everybody. Well title is saying everything. I have problem with my squad system. When script need to generate a unique ID of Squad script output always number 3 I don`t know why. I checked code five times and I don`t see anything wrong. Well here is the code :
pawn Код:
stock GetFreeSquadSlot()
{
for(new i = 0; i < MAX_SQUADS; i++)
{
if(sInfo[i][SquadID] == 0) return i;
}
return -1;
}
Anyone?
Re: Random ID for Squad`s problem -
Sanady - 12.09.2014
Anyone please I really need help. and sorry for double posting