mirror of
https://github.com/Jackzmc/sourcemod-plugins.git
synced 2025-05-06 21:33:20 +00:00
Fix faulty direct damage check
This commit is contained in:
parent
f715687724
commit
ffe5ce3e94
2 changed files with 2 additions and 2 deletions
Binary file not shown.
|
@ -281,7 +281,7 @@ Action Event_OnTakeDamage(int victim, int& attacker, int& inflictor, float& dam
|
||||||
if(GetClientTeam(attacker) != 2 || GetClientTeam(victim) != 2 || attacker == victim)
|
if(GetClientTeam(attacker) != 2 || GetClientTeam(victim) != 2 || attacker == victim)
|
||||||
return Plugin_Continue;
|
return Plugin_Continue;
|
||||||
else if(IsFakeClient(attacker) && attacker != victim) {
|
else if(IsFakeClient(attacker) && attacker != victim) {
|
||||||
// Ignore damage from fire/explosives caused by bots (players who left after causing fire)
|
// Ignore damage from fire/explosives caused by bots (players who left after causing fire)
|
||||||
if(damagetype & DMG_BURN && hFFAutoScaleActivateTypes.IntValue & view_as<int>(RffActType_MolotovDamage)) {
|
if(damagetype & DMG_BURN && hFFAutoScaleActivateTypes.IntValue & view_as<int>(RffActType_MolotovDamage)) {
|
||||||
damage = 0.0;
|
damage = 0.0;
|
||||||
return Plugin_Changed;
|
return Plugin_Changed;
|
||||||
|
@ -340,7 +340,7 @@ Action Event_OnTakeDamage(int victim, int& attacker, int& inflictor, float& dam
|
||||||
else if(pData[victim].underAttack) return Plugin_Continue;
|
else if(pData[victim].underAttack) return Plugin_Continue;
|
||||||
|
|
||||||
// Is damage not caused by fire or pipebombs?
|
// Is damage not caused by fire or pipebombs?
|
||||||
bool isDamageDirect = (damagetype & DMG_BURN) == 0;
|
bool isDamageDirect = true; //(damagetype & DMG_BURN) == 0;
|
||||||
|
|
||||||
// Forgive player teamkill based on threshold, resetting accumlated damage
|
// Forgive player teamkill based on threshold, resetting accumlated damage
|
||||||
if(time - pData[attacker].lastFFTime > hForgivenessTime.IntValue) {
|
if(time - pData[attacker].lastFFTime > hForgivenessTime.IntValue) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue