SA-MP Forums Archive
Make Pickup available for only 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)
+--- Thread: Make Pickup available for only 1 team? (/showthread.php?tid=359160)



Make Pickup available for only 1 team? - ShawtyyMacJunior - 13.07.2012

I want to make a pickup thats can be used by one team but if the other team tries to use it it doesnt work. Could anyone show me an example of how that would work?


Re: Make Pickup available for only 1 team? - Kaperstone - 13.07.2012

Depends on what you want to use.
y_classes
Defines
gTeam


Re: Make Pickup available for only 1 team? - ShawtyyMacJunior - 13.07.2012

I am using gTeam.


Re: Make Pickup available for only 1 team? - zT KiNgKoNg - 13.07.2012

thats pretty simple you use something like

pawn Код:
public OnPlayerPickupPickUp()
{
// START
// Pickup Code
if(pickup == pickup)
{
if(gTeam[playerid] == Team)
{
Your Code
}
return 1;
}
// END
return 1;
}
If this worked and helped you +REP+