TDM teams - 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: TDM teams (
/showthread.php?tid=491063)
TDM teams -
Wizardking - 29.01.2014
Hey I'm having some trouble with adding more than 1 skin for each team, I've tried a variety of things and it either doesn't work or it would be 4v2 and on the RequestClass section some cops have CRIMINALS over them and some criminals have COPS, how would I go about adding more than 1 skin for each team? This is the tutorial I got the script from.
https://sampforum.blast.hk/showthread.php?tid=346614
Re: TDM teams -
Flake. - 29.01.2014
pawn Код:
new YourTeamNameSkins[] = {
8,
42,
6
};
//OnplayerSpawn
switch(gTeam[playerid])
{
case TEAM_YourTeamName:
{
SetPlayerSkin(playerid, YourTeamNameSkin[random(3)]);
return 1;
}
//rest of your onplayerspawn code/other teams
//Sorry for the terrible indentations, forums broke it
Just took a little of my own code, it should give you a basic idea of what to do.
Re: TDM teams -
Wizardking - 29.01.2014
Quote:
Originally Posted by (*|Flake|*)
pawn Код:
new YourTeamNameSkins[] = { 8, 42, 6 };
//OnplayerSpawn switch(gTeam[playerid]) { case TEAM_YourTeamName: { SetPlayerSkin(playerid, YourTeamNameSkin[random(3)]); return 1;
}
//rest of your onplayerspawn code/other teams
//Sorry for the terrible indentations, forums broke it
Just took a little of my own code, it should give you a basic idea of what to do.
|
That would work but the GameModeText section where you see that names of the teams above the player's heads would not be updated.
Re: TDM teams -
Flake. - 29.01.2014
Quote:
Originally Posted by Wizardking
That would work but the GameModeText section where you see that names of the teams above the player's heads would not be updated.
|
pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
switch(classid)
{
case 0:
{
GameTextForPlayer(playerid, "TeamName", 5000, 2);
}
case 1:
{
//Rest of your OnplayerRequestClass stuff here
//Each class is a team according to your AddPlayerClass