Merge branch 'develop21' of https://github.com/mangoszero/server into develop21
This commit is contained in:
commit
beb3522e2a
@ -253,6 +253,9 @@ void Creature::RemoveCorpse()
|
|||||||
if (m_isCreatureLinkingTrigger)
|
if (m_isCreatureLinkingTrigger)
|
||||||
GetMap()->GetCreatureLinkingHolder()->DoCreatureLinkingEvent(LINKING_EVENT_DESPAWN, this);
|
GetMap()->GetCreatureLinkingHolder()->DoCreatureLinkingEvent(LINKING_EVENT_DESPAWN, this);
|
||||||
|
|
||||||
|
if (InstanceData* mapInstance = GetInstanceData())
|
||||||
|
{ mapInstance->OnCreatureDespawn(this); }
|
||||||
|
|
||||||
// script can set time (in seconds) explicit, override the original
|
// script can set time (in seconds) explicit, override the original
|
||||||
if (respawnDelay)
|
if (respawnDelay)
|
||||||
{ m_respawnTime = time(NULL) + respawnDelay; }
|
{ m_respawnTime = time(NULL) + respawnDelay; }
|
||||||
|
@ -99,6 +99,9 @@ class InstanceData
|
|||||||
// called on creature death
|
// called on creature death
|
||||||
virtual void OnCreatureDeath(Creature* /*creature*/) {}
|
virtual void OnCreatureDeath(Creature* /*creature*/) {}
|
||||||
|
|
||||||
|
// called on creature despawn
|
||||||
|
virtual void OnCreatureDespawn(Creature* /*creature*/) {}
|
||||||
|
|
||||||
// All-purpose data storage 64 bit
|
// All-purpose data storage 64 bit
|
||||||
virtual uint64 GetData64(uint32 /*Data*/) const { return 0; }
|
virtual uint64 GetData64(uint32 /*Data*/) const { return 0; }
|
||||||
virtual void SetData64(uint32 /*Data*/, uint64 /*Value*/) { }
|
virtual void SetData64(uint32 /*Data*/, uint64 /*Value*/) { }
|
||||||
|
Loading…
x
Reference in New Issue
Block a user