OnPlayerTakeDamage question
#1

My question might sound noobish, but I've been trying to work this problem out, testing it but the result is negative, It doesn't work, I'm trying to make like a system when-ever you get hit by a sniper you will get killed automatically

Code
pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid)
{
    if(issuerid != INVALID_PLAYER_ID)
    {
        PlayerPlaySound(issuerid, 17802, 0.0, 0.0, 0.0);
   
        if(weaponid == 34 && pInfo[issuerid][pVIP] >= 2)
        {
            SetPlayerHealth(playerid, 0);
            GameTextForPlayer(issuerid, "Sniper Kill!", 2600, 4);
        }
    }
    return 1;
}
When I press KEY_FIRE, the bullet hits me but it doesn't kill me or the player even though my sniper scope is aiming towards the target
Reply


Messages In This Thread
OnPlayerTakeDamage question - by Patrick - 22.09.2013, 12:52
Re: OnPlayerTakeDamage question - by JimmyCh - 22.09.2013, 12:56
Re: OnPlayerTakeDamage question - by Patrick - 22.09.2013, 13:04
Re: OnPlayerTakeDamage question - by DanishHaq - 22.09.2013, 13:07
Re: OnPlayerTakeDamage question - by Patrick - 22.09.2013, 13:17
Re: OnPlayerTakeDamage question - by GoldZoroGrab - 22.09.2013, 13:43
Re: OnPlayerTakeDamage question - by DanishHaq - 22.09.2013, 13:46
Re: OnPlayerTakeDamage question - by Patrick - 22.09.2013, 13:52

Forum Jump:


Users browsing this thread: 1 Guest(s)