Infection
#1

I was trying to making a infection so heres what got and my problem is that when u press key_fire u lose hp
how could i make it so if u punch the player u punch they lose hp
Example: A noob punchs a mafia the mafia loses hp

pawn Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
    if(PRESSED(KEY_FIRE)) {
        if(GetPlayerWeapon(playerid) == 4) {
            new Float:health;
            GetPlayerHealth(playerid, health);
            SetPlayerHealth(playerid, health - 50.0);
            return 1;
        }
    }
    return 1;
}
Reply


Messages In This Thread
Infection - by Kitten - 27.10.2010, 06:37
Re: Infection - by iggy1 - 27.10.2010, 06:41
Re: Infection - by Kitten - 27.10.2010, 06:44
Re: Infection - by Celson - 27.10.2010, 06:51
Re: Infection - by iggy1 - 27.10.2010, 06:53
Re: Infection - by Kitten - 27.10.2010, 06:55
Re: Infection - by Retardedwolf - 27.10.2010, 07:05
Re: Infection - by Kitten - 27.10.2010, 07:12

Forum Jump:


Users browsing this thread: 1 Guest(s)