Implement NPC Charm Stats

These combat stats an NPC will change to while charmed
This commit is contained in:
Michael Cook (mackal)
2018-02-04 16:30:16 -05:00
parent c5c93bb2e6
commit f720e51585
8 changed files with 112 additions and 2 deletions
+2
View File
@@ -790,6 +790,7 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial, int level_ove
CastToClient()->AI_Start();
} else if(IsNPC()) {
CastToNPC()->SetPetSpellID(0); //not a pet spell.
CastToNPC()->ModifyStatsOnCharm(false);
}
bool bBreak = false;
@@ -3966,6 +3967,7 @@ void Mob::BuffFadeBySlot(int slot, bool iRecalcBonuses)
if(IsNPC())
{
CastToNPC()->RestoreGuardSpotCharm();
CastToNPC()->ModifyStatsOnCharm(true);
}
SendAppearancePacket(AT_Pet, 0, true, true);