mirror of
https://github.com/mangosfour/server.git
synced 2025-12-15 01:37:00 +00:00
[11418] Add CreatureAI call JustSummoned version for GameObject*
Signed-off-by: NoFantasy <nofantasy@nf.no>
This commit is contained in:
parent
9aaa8069e2
commit
df1376b14b
3 changed files with 10 additions and 1 deletions
|
|
@ -106,6 +106,9 @@ class MANGOS_DLL_SPEC CreatureAI
|
|||
// Called when the creature summon successfully other creature
|
||||
virtual void JustSummoned(Creature* ) {}
|
||||
|
||||
// Called when the creature summon successfully a gameobject
|
||||
virtual void JustSummoned(GameObject* ) {}
|
||||
|
||||
// Called when the creature summon despawn
|
||||
virtual void SummonedCreatureDespawn(Creature* /*unit*/) {}
|
||||
|
||||
|
|
|
|||
|
|
@ -6156,6 +6156,9 @@ void Spell::EffectSummonObjectWild(SpellEffectIndex eff_idx)
|
|||
}
|
||||
|
||||
pGameObj->SummonLinkedTrapIfAny();
|
||||
|
||||
if (m_caster->GetTypeId() == TYPEID_UNIT && ((Creature*)m_caster)->AI())
|
||||
((Creature*)m_caster)->AI()->JustSummoned(pGameObj);
|
||||
}
|
||||
|
||||
void Spell::EffectScriptEffect(SpellEffectIndex eff_idx)
|
||||
|
|
@ -8696,6 +8699,9 @@ void Spell::EffectTransmitted(SpellEffectIndex eff_idx)
|
|||
cMap->Add(pGameObj);
|
||||
|
||||
pGameObj->SummonLinkedTrapIfAny();
|
||||
|
||||
if (m_caster->GetTypeId() == TYPEID_UNIT && ((Creature*)m_caster)->AI())
|
||||
((Creature*)m_caster)->AI()->JustSummoned(pGameObj);
|
||||
}
|
||||
|
||||
void Spell::EffectProspecting(SpellEffectIndex /*eff_idx*/)
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "11417"
|
||||
#define REVISION_NR "11418"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue