mod-playerbots/src/strategy/raids/gruulslair/RaidGruulsLairStrategy.cpp
Crow 983a55da86
Implement Gruul's Lair strategy (#1647)
* Implement Gruul's Lair strategy

* minor non-gameplay tweaks to code

* Use multiplier for tank assist

* HKM warlock & Gruul tank tweaks

* Fixed declarations

* rewrote HKM + minor Gruul tweaks

* Update PlayerbotAI.cpp

* modernize code and address comments

* clean ups to tank logic

* Oops.

* Remove post-move delay

For actions like positioning bosses, the standard post-movement delay should be overridden IMO since a player would be sequencing their actions in this type of situation

* Update RaidGruulsLairActions.cpp

* Replace break statements with return true

* enum class to enum

* moved all isuseful checks to triggers

* Split multipliers and improved banish logic

* Update for comments

* changes to int

* use helpers for marking icons

* address compile errors

* correct MoveTo and use RTI helper

* address comments and rename actions/triggers

* adjust alignment of location constants

* fix some crappy returns

* allow return true when changing targets

* change indents and move enums inside namespace

* style changes, trim trailing whitespaces, address comments
2025-11-04 23:01:30 +01:00

57 lines
3.4 KiB
C++

#include "RaidGruulsLairStrategy.h"
#include "RaidGruulsLairMultipliers.h"
void RaidGruulsLairStrategy::InitTriggers(std::vector<TriggerNode*>& triggers)
{
// High King Maulgar
triggers.push_back(new TriggerNode("high king maulgar is main tank", NextAction::array(0,
new NextAction("high king maulgar main tank attack maulgar", ACTION_RAID + 1), nullptr)));
triggers.push_back(new TriggerNode("high king maulgar is first assist tank", NextAction::array(0,
new NextAction("high king maulgar first assist tank attack olm", ACTION_RAID + 1), nullptr)));
triggers.push_back(new TriggerNode("high king maulgar is second assist tank", NextAction::array(0,
new NextAction("high king maulgar second assist tank attack blindeye", ACTION_RAID + 1), nullptr)));
triggers.push_back(new TriggerNode("high king maulgar is mage tank", NextAction::array(0,
new NextAction("high king maulgar mage tank attack krosh", ACTION_RAID + 1), nullptr)));
triggers.push_back(new TriggerNode("high king maulgar is moonkin tank", NextAction::array(0,
new NextAction("high king maulgar moonkin tank attack kiggler", ACTION_RAID + 1), nullptr)));
triggers.push_back(new TriggerNode("high king maulgar determining kill order", NextAction::array(0,
new NextAction("high king maulgar assign dps priority", ACTION_RAID + 1), nullptr)));
triggers.push_back(new TriggerNode("high king maulgar healer in danger", NextAction::array(0,
new NextAction("high king maulgar healer find safe position", ACTION_RAID + 1), nullptr)));
triggers.push_back(new TriggerNode("high king maulgar boss channeling whirlwind", NextAction::array(0,
new NextAction("high king maulgar run away from whirlwind", ACTION_EMERGENCY + 6), nullptr)));
triggers.push_back(new TriggerNode("high king maulgar wild felstalker spawned", NextAction::array(0,
new NextAction("high king maulgar banish felstalker", ACTION_RAID + 2), nullptr)));
triggers.push_back(new TriggerNode("high king maulgar pulling olm and blindeye", NextAction::array(0,
new NextAction("high king maulgar misdirect olm and blindeye", ACTION_RAID + 2), nullptr)));
// Gruul the Dragonkiller
triggers.push_back(new TriggerNode("gruul the dragonkiller boss engaged by main tank", NextAction::array(0,
new NextAction("gruul the dragonkiller main tank position boss", ACTION_RAID + 1), nullptr)));
triggers.push_back(new TriggerNode("gruul the dragonkiller boss engaged by range", NextAction::array(0,
new NextAction("gruul the dragonkiller spread ranged", ACTION_RAID + 1), nullptr)));
triggers.push_back(new TriggerNode("gruul the dragonkiller incoming shatter", NextAction::array(0,
new NextAction("gruul the dragonkiller shatter spread", ACTION_EMERGENCY + 6), nullptr)));
}
void RaidGruulsLairStrategy::InitMultipliers(std::vector<Multiplier*>& multipliers)
{
multipliers.push_back(new HighKingMaulgarDisableTankAssistMultiplier(botAI));
multipliers.push_back(new HighKingMaulgarAvoidWhirlwindMultiplier(botAI));
multipliers.push_back(new HighKingMaulgarDisableArcaneShotOnKroshMultiplier(botAI));
multipliers.push_back(new HighKingMaulgarDisableMageTankAOEMultiplier(botAI));
multipliers.push_back(new GruulTheDragonkillerMainTankMovementMultiplier(botAI));
multipliers.push_back(new GruulTheDragonkillerGroundSlamMultiplier(botAI));
}