mirror of
https://github.com/EQEmu/Server.git
synced 2026-03-11 07:02:35 +00:00
Tweaks to most likely wrong PVP damage reduction
This commit is contained in:
parent
d04d6750a2
commit
23bc535e23
@ -1435,13 +1435,15 @@ void Client::Damage(Mob* other, int32 damage, uint16 spell_id, EQEmu::skills::Sk
|
|||||||
// cut all PVP spell damage to 2/3
|
// cut all PVP spell damage to 2/3
|
||||||
// Blasting ourselfs is considered PvP
|
// Blasting ourselfs is considered PvP
|
||||||
//Don't do PvP mitigation if the caster is damaging himself
|
//Don't do PvP mitigation if the caster is damaging himself
|
||||||
|
//should this be applied to all damage? comments sound like some is for spell DMG
|
||||||
|
//patch notes on PVP reductions only mention archery/throwing ... not normal dmg
|
||||||
if(other && other->IsClient() && (other != this) && damage > 0) {
|
if(other && other->IsClient() && (other != this) && damage > 0) {
|
||||||
int PvPMitigation = 100;
|
int PvPMitigation = 100;
|
||||||
if (attack_skill == EQEmu::skills::SkillArchery)
|
if (attack_skill == EQEmu::skills::SkillArchery || attack_skill == EQEmu::skills::SkillThrowing)
|
||||||
PvPMitigation = 80;
|
PvPMitigation = 80;
|
||||||
else
|
else
|
||||||
PvPMitigation = 67;
|
PvPMitigation = 67;
|
||||||
damage = (damage * PvPMitigation) / 100;
|
damage = std::max((damage * PvPMitigation) / 100, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!ClientFinishedLoading())
|
if(!ClientFinishedLoading())
|
||||||
@ -3197,7 +3199,7 @@ void Mob::CommonDamage(Mob* attacker, int &damage, const uint16 spell_id, const
|
|||||||
|
|
||||||
if (!ignore_invul && (GetInvul() || DivineAura())) {
|
if (!ignore_invul && (GetInvul() || DivineAura())) {
|
||||||
Log.Out(Logs::Detail, Logs::Combat, "Avoiding %d damage due to invulnerability.", damage);
|
Log.Out(Logs::Detail, Logs::Combat, "Avoiding %d damage due to invulnerability.", damage);
|
||||||
damage = -5;
|
damage = DMG_INVULNERABLE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if( spell_id != SPELL_UNKNOWN || attacker == nullptr )
|
if( spell_id != SPELL_UNKNOWN || attacker == nullptr )
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user