debuff on melee attackers

This commit is contained in:
Yunfan Li
2023-08-28 17:28:36 +08:00
parent 953f09364a
commit 1136b7bfdc
17 changed files with 88 additions and 22 deletions

View File

@@ -54,5 +54,6 @@ void ArmsWarriorStrategy::InitTriggers(std::vector<TriggerNode*>& triggers)
triggers.push_back(new TriggerNode("bloodrage", NextAction::array(0, new NextAction("bloodrage", ACTION_HIGH + 2), nullptr)));
triggers.push_back(new TriggerNode("death wish", NextAction::array(0, new NextAction("death wish", ACTION_HIGH + 2), nullptr)));
triggers.push_back(new TriggerNode("rend", NextAction::array(0, new NextAction("rend", ACTION_HIGH + 5), nullptr)));
triggers.push_back(new TriggerNode("rend on attacker", NextAction::array(0, new NextAction("rend on attacker", ACTION_HIGH + 5), nullptr)));
triggers.push_back(new TriggerNode("critical health", NextAction::array(0, new NextAction("intimidating shout", ACTION_EMERGENCY), nullptr)));
}

View File

@@ -78,5 +78,6 @@ void TankWarriorStrategy::InitTriggers(std::vector<TriggerNode*>& triggers)
triggers.push_back(new TriggerNode("victory rush", NextAction::array(0, new NextAction("victory rush", ACTION_INTERRUPT), nullptr)));
triggers.push_back(new TriggerNode("sword and board", NextAction::array(0, new NextAction("shield slam", ACTION_INTERRUPT), nullptr)));
triggers.push_back(new TriggerNode("rend", NextAction::array(0, new NextAction("rend", ACTION_NORMAL + 1), nullptr)));
triggers.push_back(new TriggerNode("rend on attacker", NextAction::array(0, new NextAction("rend on attacker", ACTION_NORMAL + 1), nullptr)));
triggers.push_back(new TriggerNode("protect party member", NextAction::array(0, new NextAction("intervene", ACTION_EMERGENCY), nullptr)));
}

View File

@@ -28,7 +28,14 @@ BUFF_ACTION(CastCommandingShoutAction, "commanding shout");
MELEE_ACTION(CastHeroicStrikeAction, "heroic strike");
REACH_ACTION(CastChargeAction, "charge", 8.0f);
DEBUFF_CHECKISOWNER_ACTION(CastRendAction, "rend");
DEBUFF_ENEMY_ACTION(CastRendOnAttackerAction, "rend");
// DEBUFF_ENEMY_ACTION(CastRendOnAttackerAction, "rend");
class CastRendOnAttackerAction : public CastDebuffSpellOnMeleeAttackerAction
{
public:
CastRendOnAttackerAction(PlayerbotAI* botAI) : CastDebuffSpellOnMeleeAttackerAction(botAI, "rend") {}
};
DEBUFF_ACTION_R(CastThunderClapAction, "thunder clap", 8.0f);
SNARE_ACTION(CastThunderClapSnareAction, "thunder clap");
SNARE_ACTION(CastHamstringAction, "hamstring");

View File

@@ -6,6 +6,7 @@
#define _PLAYERBOT_WARRIORTRIGGERS_H
#include "GenericTriggers.h"
#include "PlayerbotAI.h"
BUFF_TRIGGER(BattleShoutTrigger, "battle shout");
BUFF_TRIGGER(BattleStanceTrigger, "battle stance");
@@ -16,7 +17,14 @@ BUFF_TRIGGER(CommandingShoutTrigger, "commanding shout");
DEBUFF_TRIGGER(DisarmDebuffTrigger, "disarm");
DEBUFF_TRIGGER(SunderArmorDebuffTrigger, "sunder armor");
DEBUFF_TRIGGER(MortalStrikeDebuffTrigger, "mortal strike");
DEBUFF_ENEMY_TRIGGER(RendDebuffOnAttackerTrigger, "rend");
// DEBUFF_ENEMY_TRIGGER(RendDebuffOnAttackerTrigger, "rend");
class RendDebuffOnAttackerTrigger : public DebuffOnMeleeAttackerTrigger
{
public:
RendDebuffOnAttackerTrigger(PlayerbotAI* botAI) : DebuffOnMeleeAttackerTrigger(botAI, "rend") {}
};
CAN_CAST_TRIGGER(RevengeAvailableTrigger, "revenge");
CAN_CAST_TRIGGER(OverpowerAvailableTrigger, "overpower");
BUFF_TRIGGER(RampageAvailableTrigger, "rampage");