Dungeon botAI bugfixes

- Utgarde Keep (Keleseth): Bots continue combat correctly after killing a frost tomb
- Utgarde Keep (Dalronn & Skarvald): Bots continue combat correctly after killing Dalronn
- Utgarde Keep (Ingvar): Tank correctly avoids Dark Smash in second phase
- Oculus (Drake combat): Bots more consistently attack the drakes in the air when flying around
- Halls of Lightning (Bjarngrim): Bots no longer acquire priority targets until in combat
This commit is contained in:
Bobblybook
2024-11-05 19:11:24 +11:00
parent fb2391d4ce
commit dd73fe8a90
9 changed files with 51 additions and 55 deletions

View File

@@ -9,9 +9,18 @@ float PrinceKelesethMultiplier::GetValue(Action* action)
Unit* boss = AI_VALUE2(Unit*, "find target", "prince keleseth");
if (!boss) { return 1.0f; }
// Suppress auto-targeting behaviour only when a tomb is up
if (dynamic_cast<DpsAssistAction*>(action))
{
return 0.0f;
GuidVector members = AI_VALUE(GuidVector, "group members");
for (auto& member : members)
{
Unit* unit = botAI->GetUnit(member);
if (unit && unit->HasAura(SPELL_FROST_TOMB))
{
return 0.0f;
}
}
}
return 1.0f;
}
@@ -19,10 +28,11 @@ float PrinceKelesethMultiplier::GetValue(Action* action)
float SkarvaldAndDalronnMultiplier::GetValue(Action* action)
{
// Only need to deal with Dalronn here. If he's dead, just fall back to normal dps strat
Unit* boss = AI_VALUE2(Unit*, "find target", "dalronn the controller");
if (!boss) { return 1.0f; }
Unit* dalronn = AI_VALUE2(Unit*, "find target", "dalronn the controller");
if (!dalronn) { return 1.0f; }
if (dynamic_cast<DpsAssistAction*>(action))
// Only suppress DpsAssistAction if Dalronn is alive
if (dalronn->isTargetableForAttack() && dynamic_cast<DpsAssistAction*>(action))
{
return 0.0f;
}