More Than 1 Team - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: More Than 1 Team (
/showthread.php?tid=64073)
More Than 1 Team -
sidhu123 - 01.02.2009
Hey hey!... [SAP]Sidhu here. I'm just making a GM and I'm stuck at one point. I want to make a command useable by ALL Police Teams, not just 1. How would I do this?.. Below is the code I have so far.
So like, 1 class is LSPD-Cops, and I want the other to be LSPD-Cop2 and SFPD-Cop
pawn Code:
if (strcmp(cmdtext, "/sfpdo", true)==0)
{
if(gTeam[playerid] == TEAM_LSPD-Cop)
{
MoveObject (sfpdgate,-1572.187622, 670.214355, 9.742842,2);
MoveObject (sfpdgate2,-1701.508301, 692.963318, 27.385559,2);
SendClientMessage(playerid, COLOR_GREEN, "The SFPD Gates Are Open!");
}
else
{
SendClientMessage(playerid, COLOR_RED, "You are not apart of the Police!");
}
return 1;
}
Re: More Than 1 Team -
Shadowww - 01.02.2009
if(gTeam[playerid] == TEAM_LSPD-Cop || gTeam[playerid] == TEAM_SFPD-Cop || gTeam[playerid] == TEAM_LVPD-Cop)
Re: More Than 1 Team -
sidhu123 - 01.02.2009
Quote:
Originally Posted by Shallot | Shadowww
if(gTeam[playerid] == TEAM_LSPD-Cop || gTeam[playerid] == TEAM_SFPD-Cop || gTeam[playerid] == TEAM_LVPD-Cop)
|
Ohh, thanks man!
I tried before, but I put:
if(gTeam[playerid] == TEAM_LSPD-Cop || if(gTeam[playerid] == TEAM_LSPD-Cop2 :P