diff --git a/src/PlayerbotAIConfig.cpp b/src/PlayerbotAIConfig.cpp index f21d0864..0ccf397c 100644 --- a/src/PlayerbotAIConfig.cpp +++ b/src/PlayerbotAIConfig.cpp @@ -162,9 +162,9 @@ bool PlayerbotAIConfig::Initialize() { for (uint32 spec = 0; spec < 3; ++spec) { - std::ostringstream os; os << "AiPlayerbot.RandomClassSpecProbability." << cls << "." << spec; + std::ostringstream os; + os << "AiPlayerbot.RandomClassSpecProbability." << cls << "." << spec; specProbability[cls][spec] = sConfigMgr->GetOption(os.str().c_str(), 33); - os.str(""); os.clear(); os << "AiPlayerbot.DefaultTalentsOrder." << cls << "." << spec; diff --git a/src/RandomPlayerbotFactory.cpp b/src/RandomPlayerbotFactory.cpp index 5284c0f2..063b3089 100644 --- a/src/RandomPlayerbotFactory.cpp +++ b/src/RandomPlayerbotFactory.cpp @@ -396,7 +396,7 @@ void RandomPlayerbotFactory::CreateRandomBots() } if (bot_creation) { - LOG_INFO("playerbots", "Wait for {} characters load into database...", totalCharCount); + LOG_INFO("playerbots", "Waiting for {} characters load into database...", totalCharCount); /* wait for characters load into database, or characters will fail to loggin */ std::this_thread::sleep_for(15ms * totalCharCount); } diff --git a/src/strategy/deathknight/DKActions.h b/src/strategy/deathknight/DKActions.h index 2457b52e..170bd0a2 100644 --- a/src/strategy/deathknight/DKActions.h +++ b/src/strategy/deathknight/DKActions.h @@ -91,8 +91,14 @@ class CastPestilenceAction : public CastSpellAction //debuff -BEGIN_DEBUFF_ACTION(CastHowlingBlastAction, "howling blast") -END_SPELL_ACTION() +// BEGIN_DEBUFF_ACTION(CastHowlingBlastAction, "howling blast") +// END_SPELL_ACTION() + +class CastHowlingBlastAction : public CastSpellAction +{ + public: + CastHowlingBlastAction(PlayerbotAI* ai) : CastSpellAction(ai, "howling blast") {} +}; //debuff it // BEGIN_DEBUFF_ACTION(CastIcyTouchAction, "icy touch") diff --git a/src/strategy/deathknight/FrostDKStrategy.cpp b/src/strategy/deathknight/FrostDKStrategy.cpp index 2a9ea33d..307801db 100644 --- a/src/strategy/deathknight/FrostDKStrategy.cpp +++ b/src/strategy/deathknight/FrostDKStrategy.cpp @@ -96,5 +96,5 @@ void FrostDKStrategy::InitTriggers(std::vector& triggers) void FrostDKAoeStrategy::InitTriggers(std::vector& triggers) { - triggers.push_back(new TriggerNode("high aoe", NextAction::array(0, new NextAction("howling blast", ACTION_NORMAL + 4), nullptr))); + triggers.push_back(new TriggerNode("medium aoe", NextAction::array(0, new NextAction("howling blast", ACTION_NORMAL + 4), nullptr))); } diff --git a/src/strategy/deathknight/GenericDKStrategy.cpp b/src/strategy/deathknight/GenericDKStrategy.cpp index e5286faa..241816eb 100644 --- a/src/strategy/deathknight/GenericDKStrategy.cpp +++ b/src/strategy/deathknight/GenericDKStrategy.cpp @@ -157,26 +157,32 @@ void GenericDKStrategy::InitTriggers(std::vector& triggers) { MeleeCombatStrategy::InitTriggers(triggers); - triggers.push_back(new TriggerNode("high aoe", NextAction::array(0, new NextAction("anti magic shell", ACTION_NORMAL + 3), nullptr))); + // triggers.push_back(new TriggerNode("high aoe", NextAction::array(0, new NextAction("anti magic shell", ACTION_NORMAL + 3), nullptr))); // triggers.push_back(new TriggerNode("death coil", NextAction::array(0, new NextAction("death coil", ACTION_NORMAL + 3), nullptr))); - triggers.push_back(new TriggerNode("critical aoe heal", NextAction::array(0, new NextAction("anti magic zone", ACTION_EMERGENCY + 1), nullptr))); + // triggers.push_back(new TriggerNode("critical aoe heal", NextAction::array(0, new NextAction("anti magic zone", ACTION_EMERGENCY + 1), nullptr))); triggers.push_back(new TriggerNode("no pet", NextAction::array(0, new NextAction("raise dead", ACTION_NORMAL + 5), nullptr))); triggers.push_back(new TriggerNode("mind freeze", NextAction::array(0, new NextAction("mind freeze", ACTION_HIGH + 1), nullptr))); + triggers.push_back(new TriggerNode("mind freeze on enemy healer", NextAction::array(0, new NextAction("mind freeze on enemy healer", ACTION_HIGH + 1), nullptr))); triggers.push_back(new TriggerNode("bone shield", NextAction::array(0, new NextAction("bone shield", ACTION_NORMAL + 1), nullptr))); triggers.push_back(new TriggerNode("horn of winter", NextAction::array(0, new NextAction("horn of winter", ACTION_NORMAL + 1), nullptr))); - triggers.push_back(new TriggerNode("mind freeze on enemy healer", NextAction::array(0, new NextAction("mind freeze on enemy healer", ACTION_HIGH + 1), nullptr))); // triggers.push_back(new TriggerNode("enemy out of melee", NextAction::array(0, new NextAction("reach melee", ACTION_NORMAL + 8), nullptr))); triggers.push_back(new TriggerNode("low health", NextAction::array(0, new NextAction("icebound fortitude", ACTION_HIGH + 5), new NextAction("rune tap", ACTION_HIGH + 4), nullptr))); triggers.push_back(new TriggerNode("medium health", NextAction::array(0, new NextAction("rune tap", ACTION_NORMAL + 4), new NextAction("death strike", ACTION_NORMAL + 3), nullptr))); - triggers.push_back(new TriggerNode("icy touch", NextAction::array(0, new NextAction("icy touch", ACTION_HIGH + 1), nullptr))); + triggers.push_back(new TriggerNode("icy touch", NextAction::array(0, new NextAction("icy touch", ACTION_HIGH + 2), nullptr))); triggers.push_back(new TriggerNode("icy touch on attacker", NextAction::array(0, new NextAction("icy touch on attacker", ACTION_HIGH + 1), nullptr))); - triggers.push_back(new TriggerNode("plague strike", NextAction::array(0, new NextAction("plague strike", ACTION_HIGH + 1), nullptr))); + triggers.push_back(new TriggerNode("plague strike", NextAction::array(0, new NextAction("plague strike", ACTION_HIGH + 2), nullptr))); triggers.push_back(new TriggerNode("plague strike on attacker", NextAction::array(0, new NextAction("plague strike on attacker", ACTION_HIGH + 1), nullptr))); - triggers.push_back(new TriggerNode("high aoe", NextAction::array(0, new NextAction("unholy blight", ACTION_HIGH + 6), new NextAction("death and decay", ACTION_NORMAL + 5), - new NextAction("pestilence", ACTION_NORMAL + 4), new NextAction("blood boil", ACTION_NORMAL + 3), nullptr))); - triggers.push_back(new TriggerNode("medium aoe", NextAction::array(0, new NextAction("death and decay", ACTION_HIGH + 9), - new NextAction("pestilence", ACTION_NORMAL + 4), new NextAction("blood boil", ACTION_NORMAL + 3), nullptr))); - triggers.push_back(new TriggerNode("light aoe", NextAction::array(0, new NextAction("howling blast", ACTION_NORMAL + 5), new NextAction("pestilence", ACTION_NORMAL + 4), - new NextAction("hearth strike", ACTION_NORMAL + 3), new NextAction("blood boil", ACTION_NORMAL + 3), nullptr))); + // triggers.push_back(new TriggerNode("high aoe", + // NextAction::array(0, + // new NextAction("death and decay", ACTION_NORMAL + 5), + // new NextAction("pestilence", ACTION_NORMAL + 4), + // new NextAction("blood boil", ACTION_NORMAL + 3), nullptr))); + triggers.push_back(new TriggerNode("medium aoe", NextAction::array(0, + new NextAction("death and decay", ACTION_HIGH + 9), + new NextAction("pestilence", ACTION_NORMAL + 4), + new NextAction("blood boil", ACTION_NORMAL + 3), nullptr))); + // triggers.push_back(new TriggerNode("light aoe", NextAction::array(0, + // new NextAction("pestilence", ACTION_NORMAL + 4), + // nullptr))); triggers.push_back(new TriggerNode("pestilence", NextAction::array(0, new NextAction("pestilence", ACTION_HIGH + 9), NULL))); } diff --git a/src/strategy/values/ExpectedLifetimeValue.cpp b/src/strategy/values/ExpectedLifetimeValue.cpp index 0d4d6352..2e41b10c 100644 --- a/src/strategy/values/ExpectedLifetimeValue.cpp +++ b/src/strategy/values/ExpectedLifetimeValue.cpp @@ -13,6 +13,7 @@ float ExpectedLifetimeValue::Calculate() // bot->Say(target->GetName() + " lifetime: " + std::to_string(res), LANG_UNIVERSAL); return res; } + float ExpectedGroupDpsValue::Calculate() { float dps_num; @@ -37,7 +38,7 @@ float ExpectedGroupDpsValue::Calculate() } else if (bot->GetLevel() < 80) { dps_efficiency = 12; } else { - dps_efficiency = 30; + dps_efficiency = 25; } return dps_num * bot->GetLevel() * dps_efficiency; } \ No newline at end of file diff --git a/src/strategy/values/ExpectedLifetimeValue.h b/src/strategy/values/ExpectedLifetimeValue.h index 5288b859..e9f432f2 100644 --- a/src/strategy/values/ExpectedLifetimeValue.h +++ b/src/strategy/values/ExpectedLifetimeValue.h @@ -28,7 +28,7 @@ class ExpectedGroupDpsValue : public FloatCalculatedValue { public: ExpectedGroupDpsValue(PlayerbotAI* botAI) : - FloatCalculatedValue(botAI, "expected group dps") { } + FloatCalculatedValue(botAI, "expected group dps", 20 * 1000) { } public: float Calculate() override; diff --git a/src/strategy/warlock/GenericWarlockNonCombatStrategy.cpp b/src/strategy/warlock/GenericWarlockNonCombatStrategy.cpp index 51ecd53f..1f55c9ae 100644 --- a/src/strategy/warlock/GenericWarlockNonCombatStrategy.cpp +++ b/src/strategy/warlock/GenericWarlockNonCombatStrategy.cpp @@ -53,7 +53,7 @@ class GenericWarlockNonCombatStrategyActionNodeFactory : public NamedObjectFacto { return new ActionNode("summon felhunter", /*P*/ nullptr, - /*A*/ NextAction::array(0, new NextAction("summon succubus"), nullptr), + /*A*/ NextAction::array(0, new NextAction("summon voidwalker"), nullptr), /*C*/ nullptr); } static ActionNode* summon_felguard([[maybe_unused]] PlayerbotAI* botAI)