[Help] Team help - 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: [Help] Team help (
/showthread.php?tid=264586)
[Help] Team help -
Twinki1993 - 26.06.2011
Okay I have attempted to make teams but here's the problem that I get.
C:\Documents and Settings\Maxa\Desktop\SAMP server\gamemodes\teams.pwn(74) : error 017: undefined symbol "SetPlayerTeamFromClass"
I am Using this code.
https://sampforum.blast.hk/showthread.php?tid=107426
Re: [Help] Team help -
[HiC]TheKiller - 26.06.2011
Make sure that this is in your code somewhere
.
pawn Код:
SetPlayerTeamFromClass(playerid, classid)
{
if(classid == 0)
{
gTeam[playerid] = TEAM_WORKERS;
SetPlayerTeam(playerid,TEAM_WORKERS);//You can delete this line if you want to allow team killing...
GameTextForPlayer(playerid,"~g~Workers",10,0);
}
else if(classid == 1)
{
gTeam[playerid] = TEAM_AGENTS;
SetPlayerTeam(playerid,TEAM_AGENTS);//Same for this!
GameTextForPlayer(playerid,"~r~Agents",10,0);
}
}
Re: [Help] Team help -
Twinki1993 - 26.06.2011
It is.
Re: [Help] Team help -
[HiC]TheKiller - 26.06.2011
Can I see your full code then?
Re: [Help] Team help -
Twinki1993 - 26.06.2011
I added full code from the link there. But still not working.
Re: [Help] Team help -
Twinki1993 - 26.06.2011
http://pastebin.com/Citkuj51 <<<--- whole thing..
Re: [Help] Team help -
[HiC]TheKiller - 26.06.2011
SetPlayerTeamFromClass needs to be outside OnPlayerRequestClass.
http://pastebin.com/k8g2K5nc
Re: [Help] Team help -
Twinki1993 - 26.06.2011
oh thanks!
Re: [Help] Team help -
Twinki1993 - 26.06.2011
Another problem..
C:\Documents and Settings\Maxa\Desktop\SAMP server\gamemodes\teams.pwn(293) : warning 203: symbol is never used: "SetPlayerTeamFromClass"
I did everything that you said but this is coming..
Re: [Help] Team help -
[HiC]TheKiller - 27.06.2011
You need to add
pawn Код:
SetPlayerTeamFromClass(playerid, classid);
Under OnPlayerRequestClass
.