09.06.2013, 11:51
OR, just use the OnPlayerTakeDamage public.
Get the team id of the issuerid and if its the same as the teamid of the playerid, you can do
There could be some mistakes made this really quick, but i think it should work.
pawn Code:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid)
pawn Code:
if(issuerid != INVALID_PLAYER_ID)
{
new Float:health, Float:newhealth;
health = GetPlayerHealth(playerid, health);
newhealth = health += amount;
SetPlayerHealth(playerid, newhealth);
}