>>>>>>>>> Help with gTeam +REP1 <<<<<<<<<<<<
#1

Hello guys ..

I will make minigames to my Server!

Example commands :
/tdm (for tdm minigames)
So on tdm i make 2 team

but how to make when the player out from minigames the player's Team = nothing ?
because i make anti team kill!
So i need when the player is not join on minigames, they can kill any players.

Thanks ..


Help me for get +REP1
Reply
#2

bump
Reply
#3

OnPlayerCommandText /quitminigame Setplayerpos and SetPlayerTeam.
Reply
#4

pawn Код:
new RandomTeams[][] =
{
    {TEAM_NAME},
    {TEAM_NAME2}
};



CMD:enterminigame(playerid, params[])
{
    new RandomTeam = random(sizeof(RandomTeams));
    SetPlayerTeam(playerid, RandomTeam[RandomTeam][0]);
    //setplayerpos etc
}

CMD:exitminigame(playerid, params[])
{
    //your setpos here
    SetPlayerTeam(playerid, 0);
    //the rest of your info on leaving here
}
Edit it of course
Reply
#5

pawn Код:
#define NONE 5

CMD:leavetdm(playerid,params[])
{
gTeam[playerid] = NONE;
return 1;
}
Reply
#6

So, let me see.

Before joining a minigame, players all have NO_TEAM and can hurt each other, right?
After joining a minigame, you change their teams (With SetPlayerTeam) so they can't hurt theyselves WHILE playing on that minigame?
If so, you have to set their team back to NO_TEAM or 255 for them to be able to damage each other again. (SetPlayerTeam(playerid, 255)

Team ID 0 is considered among the teams, you have to use 255 or NO_TEAM.
Reply
#7

Thanks guys
For your explain to me
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)