mirror of
https://github.com/EQEmu/Server.git
synced 2026-04-26 15:32:27 +00:00
Merge pull request #45 from Valorith/copilot/sub-pr-39-another-one
Fix: Spell suppression restoration for client pets with proper cleanup
This commit is contained in:
commit
db4f3d141d
@ -4695,16 +4695,13 @@ void Mob::BuffFadeBySlot(int slot, bool iRecalcBonuses, bool suppress, uint32 su
|
|||||||
client->ReapplyBuff(slot, true);
|
client->ReapplyBuff(slot, true);
|
||||||
} else if (IsPet() && GetOwner() && GetOwner()->IsClient()) {
|
} else if (IsPet() && GetOwner() && GetOwner()->IsClient()) {
|
||||||
// Reapply visual/state effects for client pets only
|
// Reapply visual/state effects for client pets only
|
||||||
// All other non-client mobs (NPCs, bots, mercs) use normal dispel mechanic
|
// Other non-client mobs (NPCs, bots, mercs) use the normal dispel mechanic
|
||||||
if (!IsValidSpell(buffs[slot].spellid))
|
|
||||||
return;
|
|
||||||
const auto& spell = spells[buffs[slot].spellid];
|
|
||||||
if (IsValidSpell(buffs[slot].spellid)) {
|
if (IsValidSpell(buffs[slot].spellid)) {
|
||||||
const auto &spell = spells[buffs[slot].spellid];
|
const auto& spell = spells[buffs[slot].spellid];
|
||||||
// Restore nimbus (visual aura) effect before processing individual spell effects,
|
// Restore nimbus (visual aura) effect before processing individual spell effects,
|
||||||
// mirroring Client::ReapplyBuff and bot buff restoration behavior.
|
// mirroring Client::ReapplyBuff behavior for client-owned pets.
|
||||||
if (spell.nimbus_effect) {
|
if (spell.nimbus_effect > 0) {
|
||||||
SetNimbusEffect(spell.nimbus_effect);
|
SetNimbusEffect(static_cast<uint32>(spell.nimbus_effect));
|
||||||
}
|
}
|
||||||
for (int i = 0; i < EFFECT_COUNT; i++) {
|
for (int i = 0; i < EFFECT_COUNT; i++) {
|
||||||
switch (spell.effect_id[i]) {
|
switch (spell.effect_id[i]) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user