fix(Scripts/Silithus): Solve issues with bosses despawing too fast (#9914)

This commit is contained in:
Skjalf
2021-12-29 09:23:34 -03:00
committed by GitHub
parent 7b7d9b3aed
commit 1a75b3ef0d

View File

@@ -1185,7 +1185,8 @@ public:
return; return;
} }
player->CastSpell(player, spellInfoTrigger->Id, false); player->CastSpell(player, spellInfoTrigger->Id, false);
if (TempSummon* summons = go->SummonCreature(npc, go->GetPositionX(), go->GetPositionY(), go->GetPositionZ(), player->GetOrientation() - M_PI, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 6000)) // @todo: this is not correct! should despawn 5-6 seconds when out of combat, but can't be handled by tempsummon timer alone apparently
if (TempSummon* summons = go->SummonCreature(npc, go->GetPositionX(), go->GetPositionY(), go->GetPositionZ(), player->GetOrientation() - M_PI, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5 * 60 * 1000))
{ {
summons->SetTarget(player->GetGUID()); summons->SetTarget(player->GetGUID());
summons->SetLootRecipient(player); summons->SetLootRecipient(player);