mirror of
https://github.com/araxiaonline/TrinityCore.git
synced 2026-06-14 20:22:23 -04:00
Entities/Creature: Add arg2 to DespawnOrUnsummon to allow overriding respawn time. This matches changes that will be merged as part of dynamic spawning, allowing scripts to transition early.
This commit is contained in:
@@ -573,16 +573,7 @@ void BossAI::_DespawnAtEvade(uint32 delayToRespawn, Creature* who)
|
||||
return;
|
||||
}
|
||||
|
||||
uint32 corpseDelay = who->GetCorpseDelay();
|
||||
uint32 respawnDelay = who->GetRespawnDelay();
|
||||
|
||||
who->SetCorpseDelay(1);
|
||||
who->SetRespawnDelay(delayToRespawn - 1);
|
||||
|
||||
who->DespawnOrUnsummon();
|
||||
|
||||
who->SetCorpseDelay(corpseDelay);
|
||||
who->SetRespawnDelay(respawnDelay);
|
||||
me->DespawnOrUnsummon(0, Seconds(delayToRespawn));
|
||||
|
||||
if (instance && who == me)
|
||||
instance->SetBossState(_bossId, FAIL);
|
||||
|
||||
Reference in New Issue
Block a user