Damage help!
#1

Hello, I am trying to script in realistic damage for a script yet I do not know how to tell the script, if the player has armor to "Attack the armor first" Not just the HP... here is it so far!

Код:
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid)
{
    new Float:HP;
    GetPlayerHealth(playerid, HP);
    if(weaponid == 24) SetPlayerHealth(playerid, HP-40);//DesertEagle
    if(weaponid == 22) SetPlayerHealth(playerid, HP-30);//Colt45
    if(weaponid == 32) SetPlayerHealth(playerid, HP-15);//Tec9
    if(weaponid == 28) SetPlayerHealth(playerid, HP-15);//Uzi
    if(weaponid == 23) SetPlayerHealth(playerid, HP-35);//SilencedColt
    if(weaponid == 31) SetPlayerHealth(playerid, HP-37);//M4
    if(weaponid == 30) SetPlayerHealth(playerid, HP-34);//AK
    if(weaponid == 29) SetPlayerHealth(playerid, HP-18);//MP5
    if(weaponid == 34) SetPlayerHealth(playerid, HP-300);//SniperRifle
    if(weaponid == 33) SetPlayerHealth(playerid, HP-35);//CuntGun
    if(weaponid == 25) SetPlayerHealth(playerid, HP-40);//PumpShotgun
    if(weaponid == 27) SetPlayerHealth(playerid, HP-30);//Spaz12
    return 1;
}
Any help will be appreciated
Reply


Messages In This Thread
Damage help! - by Zachlive - 14.09.2012, 00:55
Re: Damage help! - by Lordzy - 14.09.2012, 01:05
Re: Damage help! - by Zachlive - 14.09.2012, 01:28
Re: Damage help! - by Zachlive - 14.09.2012, 21:57
Re: Damage help! - by clarencecuzz - 14.09.2012, 22:57
Re: Damage help! - by SuperViper - 14.09.2012, 23:22
Re: Damage help! - by KoczkaHUN - 14.09.2012, 23:32

Forum Jump:


Users browsing this thread: 2 Guest(s)