Warrior strategy update (#838)

* Enraged regen at critial health

* Enraged regen action context

* Enraged regen on critical health trigger

* Enraged regen on critical health trigger

* Added logic for Arms to use Retaliation

* Added logic for Arms to use Retaliation

* Used correct class enums for !players

* Retaliation on medium health

* Removed temp line

* Added check for attacker->GetVictim() != bot

* Adjusted triggers for emergency actions

* Added Shattering Throw logic

* Added Shattering Throw logic

* Added Shattering Throw logic

* Added Shattering Throw logic

* Added Shattering Throw logic

* Added Shattering Throw logic

* Fixed ActionNode for Shattering Throw

* Added debug logging

* More debug logs

* Better debug logs

* Adjusted range on action

* Adjusted priorities

* More logging

* Update WarriorActions.cpp

* Update WarriorActions.h

* Changed trigger name for differentiation

* Updated to new shattering throw trigger name

* Update WarriorTriggers.h with new ST name

* Update ArmsWarriorStrategy.cpp

* Changed priority

* Shattering Throw and Retaliation stance reqs

Battlestance needed for Shattering Throw and Retaliation

* Created isUseful for Shattering Throw

* Created isUseful for Shattering Throw

* GetTarget instead of GetTargetValue

* Changed to GetTarget instead of GetTargetValue

* Commented out Execute function

* Commented out Execute function

* isPossible was failing, created basic isPossible

IsImmuneToSpell was returning true for Shattering Throw

2 DAYS! :(

* isPossible was failing, created basic isPossible

* Added some more isPossible checks

* Update WarriorActions.cpp

* Missing )

* Missing !

* Removed logging

* Removed logging

* Clean up

* Cleanup

* Corrected logic for Rogue's Expose Armor trigger

Logic was checking the Rogue, not the Rogue's target, for Sunder Armor before casting Expose Armor.
This commit is contained in:
avirar
2025-01-04 02:06:47 +11:00
committed by GitHub
parent c59c0cc802
commit 739a0df44c
10 changed files with 279 additions and 7 deletions

View File

@@ -17,6 +17,9 @@ public:
creators["piercing howl"] = &piercing_howl;
creators["mocking blow"] = &mocking_blow;
creators["heroic strike"] = &heroic_strike;
creators["enraged regeneration"] = &enraged_regeneration;
creators["retaliation"] = &retaliation;
creators["shattering throw"] = &shattering_throw;
}
private:
@@ -25,6 +28,30 @@ private:
ACTION_NODE_A(piercing_howl, "piercing howl", "mocking blow");
ACTION_NODE_A(mocking_blow, "mocking blow", "hamstring");
ACTION_NODE_A(heroic_strike, "heroic strike", "melee");
static ActionNode* enraged_regeneration(PlayerbotAI* botAI)
{
return new ActionNode("enraged regeneration",
/*P*/ nullptr,
/*A*/ nullptr,
/*C*/ nullptr);
}
static ActionNode* retaliation(PlayerbotAI* botAI)
{
return new ActionNode("retaliation",
/*P*/ nullptr,
/*A*/ nullptr,
/*C*/ nullptr);
}
static ActionNode* shattering_throw(PlayerbotAI* botAI)
{
return new ActionNode("shattering throw",
/*P*/ nullptr,
/*A*/ nullptr,
/*C*/ nullptr);
}
};
ArmsWarriorStrategy::ArmsWarriorStrategy(PlayerbotAI* botAI) : GenericWarriorStrategy(botAI)
@@ -93,9 +120,18 @@ void ArmsWarriorStrategy::InitTriggers(std::vector<TriggerNode*>& triggers)
triggers.push_back(
new TriggerNode("death wish", NextAction::array(0, new NextAction("death wish", ACTION_HIGH + 2), nullptr)));
triggers.push_back(new TriggerNode(
"critical health", NextAction::array(0, new NextAction("intimidating shout", ACTION_EMERGENCY), nullptr)));
triggers.push_back(new TriggerNode("critical health",
NextAction::array(0, new NextAction("intimidating shout", ACTION_EMERGENCY), nullptr)));
triggers.push_back(new TriggerNode("medium health",
NextAction::array(0, new NextAction("enraged regeneration", ACTION_EMERGENCY), nullptr)));
triggers.push_back(new TriggerNode("almost full health",
NextAction::array(0, new NextAction("retaliation", ACTION_EMERGENCY + 1), nullptr)));
triggers.push_back(new TriggerNode("shattering throw trigger",
NextAction::array(0, new NextAction("shattering throw", ACTION_INTERRUPT + 1), nullptr)));
// triggers.push_back(new TriggerNode("medium aoe",
// NextAction::array(0, new NextAction("thunder clap", ACTION_HIGH + 2), nullptr)));
/*