SA-MP Forums Archive
Team Kills - 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: Team Kills (/showthread.php?tid=264058)



Team Kills - 0_o - 24.06.2011

How to Count Total Kills of each Team?


Re: Team Kills - Mauzen - 24.06.2011

In OnPlayerDeath

if (team[playerid] == team[killerid]) teamkills[killerid] ++;

Replace team with whatever system you use for teams


Re: Team Kills - Wesley221 - 24.06.2011

This is just a rough example, but it will give you an idea how you can do it

pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
    if(GetPlayerTeam(playerid) == 0)
    {
        Team1Count++;
    }
    if(GetPlayerTeam(playerid) == 1)
    {
        Team0Count++;
    }
    return 1;
}
Edit: im late once again


Re: Team Kills - 0_o - 24.06.2011

How Can I Get Team Score High Onplayerdeath And Show The Highest Team Score To All?


Re: Team Kills - GangsTa_ - 24.06.2011

It's not that easy to show off how to make such systems, just think yourself - with variables & meditation you'll make it to the final!


Re: Team Kills - Mauzen - 24.06.2011

Quote:
Originally Posted by 0_o
Посмотреть сообщение
How Can I Get Team Score High Onplayerdeath And Show The Highest Team Score To All?
With the forum search