aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/server/scripts/EasternKingdoms/zone_stranglethorn_vale.cpp24
1 files changed, 14 insertions, 10 deletions
diff --git a/src/server/scripts/EasternKingdoms/zone_stranglethorn_vale.cpp b/src/server/scripts/EasternKingdoms/zone_stranglethorn_vale.cpp
index 3000c30c8e7..5783d6782ba 100644
--- a/src/server/scripts/EasternKingdoms/zone_stranglethorn_vale.cpp
+++ b/src/server/scripts/EasternKingdoms/zone_stranglethorn_vale.cpp
@@ -36,6 +36,14 @@ EndContentData */
## npc_yenniku
######*/
+enum Yenniku
+{
+ SPELL_YENNIKUS_RELEASE = 3607,
+ QUEST_SAVING_YENNIKU = 592,
+ FACTION_HORDE_GENERIC = 83,
+ FACTION_TROLL_BLOODSCALP = 28
+};
+
class npc_yenniku : public CreatureScript
{
public:
@@ -70,17 +78,17 @@ public:
void SpellHit(Unit* caster, const SpellInfo* spell) override
{
- if (bReset || spell->Id != 3607)
+ if (bReset || spell->Id != SPELL_YENNIKUS_RELEASE)
return;
if (Player* player = caster->ToPlayer())
{
- if (player->GetQuestStatus(592) == QUEST_STATUS_INCOMPLETE) //Yenniku's Release
+ if (player->GetQuestStatus(QUEST_SAVING_YENNIKU) == QUEST_STATUS_INCOMPLETE) // Yenniku's Release
{
me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_STUN);
- me->CombatStop(); //stop combat
- me->DeleteThreatList(); //unsure of this
- me->setFaction(83); //horde generic
+ me->CombatStop(); // stop combat
+ me->DeleteThreatList(); // unsure of this
+ me->setFaction(FACTION_HORDE_GENERIC); // horde generic
bReset = true;
Reset_Timer = 60000;
@@ -98,7 +106,7 @@ public:
{
EnterEvadeMode();
bReset = false;
- me->setFaction(28); //troll, bloodscalp
+ me->setFaction(FACTION_TROLL_BLOODSCALP); // troll, bloodscalp
return;
}
@@ -126,10 +134,6 @@ public:
};
};
-/*######
-##
-######*/
-
void AddSC_stranglethorn_vale()
{
new npc_yenniku();