mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-16 18:52:22 +00:00
[Cleanup] Move unreachable code in ApplySpellsBonuses() (#3229)
# Notes - This code was unreachable since it was inside the switch and should have been checked on its own in the condition where we verify we are using AISpellEffects.
This commit is contained in:
+11
-13
@@ -2115,10 +2115,17 @@ void Mob::ApplySpellsBonuses(uint16 spell_id, uint8 casterlevel, StatBonuses *ne
|
||||
//Use AISpellEffects
|
||||
else {
|
||||
spell_effect_id = effect_id;
|
||||
effect_value = se_base;
|
||||
limit_value = se_limit;
|
||||
max_value = se_max;
|
||||
i = (EFFECT_COUNT - 1); // AISpellEffects do a single pass
|
||||
effect_value = se_base;
|
||||
limit_value = se_limit;
|
||||
max_value = se_max;
|
||||
|
||||
//Special custom cases for loading effects on to NPC from 'npc_spels_effects' table
|
||||
//Non-Focused Effect to modify incoming spell damage by resist type.
|
||||
if (spell_effect_id == SE_FcSpellVulnerability) {
|
||||
ModVulnerability(limit_value, effect_value);
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
switch (spell_effect_id)
|
||||
@@ -4068,15 +4075,6 @@ void Mob::ApplySpellsBonuses(uint16 spell_id, uint8 casterlevel, StatBonuses *ne
|
||||
case SE_TrapCircumvention:
|
||||
new_bonus->TrapCircumvention += effect_value;
|
||||
break;
|
||||
|
||||
//Special custom cases for loading effects on to NPC from 'npc_spels_effects' table
|
||||
if (IsAISpellEffect) {
|
||||
|
||||
//Non-Focused Effect to modify incoming spell damage by resist type.
|
||||
case SE_FcSpellVulnerability:
|
||||
ModVulnerability(limit_value, effect_value);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user