21.04.2018, 19:38
Quote:
Код:
public OnPlayerDamage(&playerid, &Float:amount, &issuerid, &weapon, &bodypart) { if (weapon == WEAPON_CARPARK || weapon == WEAPON_HELIBLADES) // Disable helikill and carpark return false; new avg_rate = AverageShootRate(issuerid, 2); // Lower rapid fire damage if (avg_rate != -1) { if (weapon == WEAPON_DEAGLE && avg_rate < 500) { amount /= 1.4; } else if (weapon == WEAPON_SHOTGSPA && avg_rate < 250) { amount /= 1.4; } } // Silencer headshot if (weapon == WEAPON_SILENCED && bodypart == 9) { amount = 30.0; } // Rifle headshot if (weapon == WEAPON_RIFLE && bodypart == 9) { amount /= 0.75; } // Sniper headshot if (weapon == WEAPON_SNIPER && bodypart == 9) { if (amount == 30.0) { amount = 40.0; } else if (amount == 35.0) { amount = 40.0; } else if (amount == 45.0) { amount = 50.0; } } return true; } |