From 5956875caebc2525183fddc9540def7043b29388 Mon Sep 17 00:00:00 2001 From: Yunfan Li Date: Fri, 14 Jul 2023 15:21:40 +0800 Subject: [PATCH] frost presence for blood dk --- src/strategy/deathknight/BloodDKStrategy.cpp | 10 ++++++++-- src/strategy/deathknight/DKActions.cpp | 5 ----- src/strategy/deathknight/DKActions.h | 2 -- 3 files changed, 8 insertions(+), 9 deletions(-) diff --git a/src/strategy/deathknight/BloodDKStrategy.cpp b/src/strategy/deathknight/BloodDKStrategy.cpp index dce7ec9e..c3b8e23e 100644 --- a/src/strategy/deathknight/BloodDKStrategy.cpp +++ b/src/strategy/deathknight/BloodDKStrategy.cpp @@ -18,7 +18,7 @@ class BloodDKStrategyActionNodeFactory : public NamedObjectFactory //creators["death grip"] = &death_grip; //creators["plague strike"] = &plague_strike; //creators["pestilence"] = &pestilence; - //creators["icy touch"] = &icy_touch; + creators["icy touch"] = &icy_touch; //creators["obliterate"] = &obliterate; //creators["blood boil"] = &blood_boil; //creators["mark of_blood"] = &mark_of_blood; @@ -41,7 +41,13 @@ class BloodDKStrategyActionNodeFactory : public NamedObjectFactory /*A*/ nullptr, /*C*/ nullptr); } - + static ActionNode* icy_touch([[maybe_unused]] PlayerbotAI* botAI) + { + return new ActionNode("icy touch", + /*P*/ NextAction::array(0, new NextAction("frost presence"), nullptr), + /*A*/ nullptr, + /*C*/ nullptr); + } static ActionNode* heart_strike([[maybe_unused]] PlayerbotAI* botAI) { return new ActionNode ("heart strike", diff --git a/src/strategy/deathknight/DKActions.cpp b/src/strategy/deathknight/DKActions.cpp index a686b512..e0f5b824 100644 --- a/src/strategy/deathknight/DKActions.cpp +++ b/src/strategy/deathknight/DKActions.cpp @@ -14,11 +14,6 @@ NextAction** CastDeathchillAction::getPrerequisites() return NextAction::merge(NextAction::array(0, new NextAction("frost presence"), nullptr), CastSpellAction::getPrerequisites()); } -NextAction** CastDarkCommandAction::getPrerequisites() -{ - return NextAction::merge(NextAction::array(0, new NextAction("blood presence"), nullptr), CastSpellAction::getPrerequisites()); -} - NextAction** CastUnholyMeleeSpellAction::getPrerequisites() { return NextAction::merge(NextAction::array(0, new NextAction("unholy presence"), nullptr), CastMeleeSpellAction::getPrerequisites()); diff --git a/src/strategy/deathknight/DKActions.h b/src/strategy/deathknight/DKActions.h index ad987cbc..ff7407c6 100644 --- a/src/strategy/deathknight/DKActions.h +++ b/src/strategy/deathknight/DKActions.h @@ -40,8 +40,6 @@ class CastDarkCommandAction : public CastSpellAction { public: CastDarkCommandAction(PlayerbotAI* botAI) : CastSpellAction(botAI, "dark command") { } - - NextAction** getPrerequisites() override; }; BEGIN_RANGED_SPELL_ACTION(CastDeathGripAction, "death grip")