Team Kill Help +Rep
#2

Reply back if this doesn't work, I haven't tested it out. What the code is doing is checking the teams of both the person shooting and the person who was shot. If the shooter is a soldier shooting a human, it gives the human his health back and returns an error to the soldier.
pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid)
{
    if(gTeam[issuerid] == SOLDIER && gTeam[playerid] == HUMAN) SetPlayerHealth(playerid,+amount) && SendClientMessage(issuerid,color,"You cannot shoot humans, aim for the zombies!");
}
Reply


Messages In This Thread
Team Kill Help +Rep - by Deaglez - 16.09.2012, 02:47
Re: Team Kill Help +Rep - by zDevon - 16.09.2012, 02:55
Re: Team Kill Help +Rep - by Deaglez - 16.09.2012, 03:00
Re: Team Kill Help +Rep - by YourLord - 16.09.2012, 03:03
Re: Team Kill Help +Rep - by zDevon - 16.09.2012, 03:07
Re: Team Kill Help +Rep - by Deaglez - 16.09.2012, 04:22
Re: Team Kill Help +Rep - by Deaglez - 16.09.2012, 04:26

Forum Jump:


Users browsing this thread: 1 Guest(s)