mirror of
https://github.com/mod-playerbots/mod-playerbots.git
synced 2026-01-21 20:46:22 +00:00
Warlock overhaul (#1397)
This is a complete overhaul of the warlock class, making 3 new strategies (affliction, demonology, and destruction), as well as finishing the warlock tank strategy (shadow ward and searing pain). It also includes a soulstone fix, where the bots can change who they soulstone based on the non-combat strategies you set for them. It also includes a self-resurrect action and trigger that allows the bots to resurrect using a soulstone or reincarnation. Many other skills were added to finish out the warlock skillset.
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
#include "HealthTriggers.h"
|
||||
#include "RangeTriggers.h"
|
||||
#include "Trigger.h"
|
||||
#include "Player.h"
|
||||
|
||||
class PlayerbotAI;
|
||||
class Unit;
|
||||
@@ -922,4 +923,13 @@ public:
|
||||
public:
|
||||
virtual Value<Unit*>* GetTargetValue();
|
||||
};
|
||||
|
||||
class SelfResurrectTrigger : public Trigger
|
||||
{
|
||||
public:
|
||||
SelfResurrectTrigger(PlayerbotAI* ai) : Trigger(ai, "can self resurrect") {}
|
||||
|
||||
bool IsActive() override { return !bot->IsAlive() && bot->GetUInt32Value(PLAYER_SELF_RES_SPELL); }
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -223,6 +223,7 @@ public:
|
||||
creators["near random status"] = &TriggerContext::near_random_status;
|
||||
creators["near npc status"] = &TriggerContext::near_npc_status;
|
||||
creators["do quest status"] = &TriggerContext::do_quest_status;
|
||||
creators["can self resurrect"] = &TriggerContext::can_self_resurrect;
|
||||
}
|
||||
|
||||
private:
|
||||
@@ -420,6 +421,7 @@ private:
|
||||
static Trigger* near_random_status(PlayerbotAI* botAI) { return new NewRpgStatusTrigger(botAI, RPG_NEAR_RANDOM); }
|
||||
static Trigger* near_npc_status(PlayerbotAI* botAI) { return new NewRpgStatusTrigger(botAI, RPG_NEAR_NPC); }
|
||||
static Trigger* do_quest_status(PlayerbotAI* botAI) { return new NewRpgStatusTrigger(botAI, RPG_DO_QUEST); }
|
||||
static Trigger* can_self_resurrect(PlayerbotAI* ai) { return new SelfResurrectTrigger(ai); }
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user