02.10.2012, 04:16
I look at this.Thread for helping with adding teams.>>> https://sampforum.blast.hk/showthread.php?tid=160810
On that thread I dont understand this part.
This basically added a player who spawns, to the appropriate team Color. But nothing will work unless you have this next few lines scripted. To be able to determine whether you're a cop or a gang member, you must make sure you Set the Player Team from the Class. So underneath everything script this:
I dont know where to add this at?
pawn Code:
SetPlayerTeamFromClass(playerid, classid)
{
if(classid == 0)
{
gTeam[playerid] = GROVE_STREET;
}
}
Next you will tell gTeam, that this is a Grove Street Gang Member, and his nametag should be green. So next add this under everything:
I dont know where to add this at?
pawn Code:
SetPlayerToTeamColour(playerid)
{
if(gTeam[playerid] == GROVE_STREET)
{
SetPlayerColor(playerid,GROVE_STREET_COLOUR); //Green
}
}
This basically sets the Grove Street Gang Member to the Grove Street Color, we had defined earlier which was green, so, now this nametag is green. Now Lets add the Police the exact same way. It should look something like this:
I also dont know where to add this at?
pawn Code:
SetPlayerTeamFromClass(playerid, classid)
{
if(classid == 0)
{
gTeam[playerid] = GROVE_STREET;
}
if(classid == 1)
{
gTeam[playerid] = POLICE;
}
}
SetPlayerToTeamColour(playerid)
{
if(gTeam[playerid] == GROVE_STREET)
{
SetPlayerColor(playerid,GROVE_STREET_COLOUR); //Green
}
if(gTeam[playerid] == POLICE)
{
SetPlayerColor(playerid,POLICE_COLOUR); // Blue
}
}
Anyway,I did the rest of the steps.Instead,of the problems that I needed help with.When I compile the stuff I did.I get this error.So,please help me guys.I know this is a huge thread and problem.
C:\Documents and Settings\Owner\My Documents\GTA - San Andreas\Server\gamemodes\Z.pwn(160) : error 017: undefined symbol "SetPlayerTeamFromClass"
C:\Documents and Settings\Owner\My Documents\GTA - San Andreas\Server\gamemodes\Z.pwn(18 : error 017: undefined symbol "SetPlayerToTeamColour"
C:\Documents and Settings\Owner\My Documents\GTA - San Andreas\Server\gamemodes\Z.pwn(370) : warning 203: symbol is never used: "gTeam"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
2 Errors.
On that thread I dont understand this part.
This basically added a player who spawns, to the appropriate team Color. But nothing will work unless you have this next few lines scripted. To be able to determine whether you're a cop or a gang member, you must make sure you Set the Player Team from the Class. So underneath everything script this:
I dont know where to add this at?
pawn Code:
SetPlayerTeamFromClass(playerid, classid)
{
if(classid == 0)
{
gTeam[playerid] = GROVE_STREET;
}
}
Next you will tell gTeam, that this is a Grove Street Gang Member, and his nametag should be green. So next add this under everything:
I dont know where to add this at?
pawn Code:
SetPlayerToTeamColour(playerid)
{
if(gTeam[playerid] == GROVE_STREET)
{
SetPlayerColor(playerid,GROVE_STREET_COLOUR); //Green
}
}
This basically sets the Grove Street Gang Member to the Grove Street Color, we had defined earlier which was green, so, now this nametag is green. Now Lets add the Police the exact same way. It should look something like this:
I also dont know where to add this at?
pawn Code:
SetPlayerTeamFromClass(playerid, classid)
{
if(classid == 0)
{
gTeam[playerid] = GROVE_STREET;
}
if(classid == 1)
{
gTeam[playerid] = POLICE;
}
}
SetPlayerToTeamColour(playerid)
{
if(gTeam[playerid] == GROVE_STREET)
{
SetPlayerColor(playerid,GROVE_STREET_COLOUR); //Green
}
if(gTeam[playerid] == POLICE)
{
SetPlayerColor(playerid,POLICE_COLOUR); // Blue
}
}
Anyway,I did the rest of the steps.Instead,of the problems that I needed help with.When I compile the stuff I did.I get this error.So,please help me guys.I know this is a huge thread and problem.
C:\Documents and Settings\Owner\My Documents\GTA - San Andreas\Server\gamemodes\Z.pwn(160) : error 017: undefined symbol "SetPlayerTeamFromClass"
C:\Documents and Settings\Owner\My Documents\GTA - San Andreas\Server\gamemodes\Z.pwn(18 : error 017: undefined symbol "SetPlayerToTeamColour"
C:\Documents and Settings\Owner\My Documents\GTA - San Andreas\Server\gamemodes\Z.pwn(370) : warning 203: symbol is never used: "gTeam"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
2 Errors.