Skip to content

Commit

Permalink
fix bossai merge relic
Browse files Browse the repository at this point in the history
  • Loading branch information
insunaa committed Aug 13, 2023
1 parent da3e3d5 commit d23ec72
Showing 1 changed file with 0 additions and 38 deletions.
38 changes: 0 additions & 38 deletions src/game/AI/ScriptDevAI/base/BossAI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,41 +132,3 @@ void BossAI::DespawnSubordinateOnEvade(ObjectGuid guid)
{
m_despawnSubordinateOnEvade.push_back(guid);
}

void BossAI::EnterEvadeMode()
{
if (m_respawnDelay == -1)
{
CombatAI::EnterEvadeMode();
return;
}
m_creature->SetRespawnDelay(m_respawnDelay);
m_creature->ForcedDespawn();
for (ObjectGuid& guid : m_despawnSubordinateOnEvade)
{
Creature* addToDespawn = m_creature->GetMap()->GetCreature(guid);
if (!addToDespawn)
continue;
addToDespawn->SetRespawnDelay(m_respawnDelay);
addToDespawn->ForcedDespawn();
}
if (m_instanceDataType == -1)
return;
if (ScriptedInstance* instance = static_cast<ScriptedInstance*>(m_creature->GetInstanceData()))
instance->SetData(m_instanceDataType, FAIL);
}

void BossAI::AddCastOnDeath(QueuedCast cast)
{
m_castOnDeath.push_back(cast);
}

void BossAI::AddRespawnOnEvade(std::chrono::milliseconds delay)
{
m_respawnDelay = delay.count();
}

void BossAI::DespawnSubordinateOnEvade(ObjectGuid guid)
{
m_despawnSubordinateOnEvade.push_back(guid);
}

0 comments on commit d23ec72

Please sign in to comment.