mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-19 17:05:44 +01:00
*quest 12231 - The Bear God's Offspring, by Destalker
*SD2 enum escort faction, patch by manuel *Extend the Chathandler to TrinityScript, by Hawthorne --HG-- branch : trunk
This commit is contained in:
@@ -17,6 +17,7 @@
|
||||
#include "sc_instance.h"
|
||||
#include "CombatAI.h"
|
||||
#include "PassiveAI.h"
|
||||
#include "Chat.h"
|
||||
|
||||
#ifdef WIN32
|
||||
#include <windows.h>
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
/* ScriptData
|
||||
SDName: Grizzly_Hills
|
||||
SD%Complete: 80
|
||||
SDComment: Quest support: 12247
|
||||
SDComment: Quest support: 12231, 12247
|
||||
SDCategory: Grizzly Hills
|
||||
EndScriptData */
|
||||
|
||||
@@ -49,7 +49,8 @@ enum
|
||||
NPC_ORSONN_CREDIT = 27322,
|
||||
NPC_KODIAN_CREDIT = 27321,
|
||||
|
||||
QUEST_CHILDREN_OF_URSOC = 12247
|
||||
QUEST_CHILDREN_OF_URSOC = 12247,
|
||||
QUEST_THE_BEAR_GODS_OFFSPRING = 12231
|
||||
};
|
||||
|
||||
bool GossipHello_npc_orsonn_and_kodian(Player* pPlayer, Creature* pCreature)
|
||||
@@ -57,12 +58,12 @@ bool GossipHello_npc_orsonn_and_kodian(Player* pPlayer, Creature* pCreature)
|
||||
if (pCreature->isQuestGiver())
|
||||
pPlayer->PrepareQuestMenu(pCreature->GetGUID());
|
||||
|
||||
if (pPlayer->GetQuestStatus(QUEST_CHILDREN_OF_URSOC) == QUEST_STATUS_INCOMPLETE)
|
||||
if (pPlayer->GetQuestStatus(QUEST_CHILDREN_OF_URSOC) == QUEST_STATUS_INCOMPLETE || pPlayer->GetQuestStatus(QUEST_THE_BEAR_GODS_OFFSPRING) == QUEST_STATUS_INCOMPLETE)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
{
|
||||
case NPC_ORSONN:
|
||||
if (!pPlayer->GetReqKillOrCastCurrentCount(QUEST_CHILDREN_OF_URSOC, NPC_ORSONN_CREDIT))
|
||||
if (!pPlayer->GetReqKillOrCastCurrentCount(QUEST_CHILDREN_OF_URSOC, NPC_ORSONN_CREDIT) || !pPlayer->GetReqKillOrCastCurrentCount(QUEST_THE_BEAR_GODS_OFFSPRING, NPC_ORSONN_CREDIT))
|
||||
{
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_ORSONN1, pCreature->GetGUID());
|
||||
@@ -70,7 +71,7 @@ bool GossipHello_npc_orsonn_and_kodian(Player* pPlayer, Creature* pCreature)
|
||||
}
|
||||
break;
|
||||
case NPC_KODIAN:
|
||||
if (!pPlayer->GetReqKillOrCastCurrentCount(QUEST_CHILDREN_OF_URSOC, NPC_KODIAN_CREDIT))
|
||||
if (!pPlayer->GetReqKillOrCastCurrentCount(QUEST_CHILDREN_OF_URSOC, NPC_KODIAN_CREDIT) || !pPlayer->GetReqKillOrCastCurrentCount(QUEST_THE_BEAR_GODS_OFFSPRING, NPC_KODIAN_CREDIT))
|
||||
{
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM4, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+4);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_KODIAN1, pCreature->GetGUID());
|
||||
|
||||
@@ -9,6 +9,30 @@ extern DatabaseType TScriptDB;
|
||||
|
||||
#define TEXT_SOURCE_RANGE -1000000 //the amount of entries each text source has available
|
||||
|
||||
//TODO: find better namings and definitions.
|
||||
//N=Neutral, A=Alliance, H=Horde.
|
||||
//NEUTRAL or FRIEND = Hostility to player surroundings (not a good definition)
|
||||
//ACTIVE or PASSIVE = Hostility to environment surroundings.
|
||||
enum eEscortFaction
|
||||
{
|
||||
FACTION_ESCORT_A_NEUTRAL_PASSIVE = 10,
|
||||
FACTION_ESCORT_H_NEUTRAL_PASSIVE = 33,
|
||||
FACTION_ESCORT_N_NEUTRAL_PASSIVE = 113,
|
||||
|
||||
FACTION_ESCORT_A_NEUTRAL_ACTIVE = 231,
|
||||
FACTION_ESCORT_H_NEUTRAL_ACTIVE = 232,
|
||||
FACTION_ESCORT_N_NEUTRAL_ACTIVE = 250,
|
||||
|
||||
FACTION_ESCORT_N_FRIEND_PASSIVE = 290,
|
||||
FACTION_ESCORT_N_FRIEND_ACTIVE = 495,
|
||||
|
||||
FACTION_ESCORT_A_PASSIVE = 774,
|
||||
FACTION_ESCORT_H_PASSIVE = 775,
|
||||
|
||||
FACTION_ESCORT_N_ACTIVE = 1986,
|
||||
FACTION_ESCORT_H_ACTIVE = 2046
|
||||
};
|
||||
|
||||
struct ScriptPointMove
|
||||
{
|
||||
uint32 uiCreatureEntry;
|
||||
|
||||
@@ -41,7 +41,7 @@ class ChatCommand
|
||||
ChatCommand * ChildCommands;
|
||||
};
|
||||
|
||||
class ChatHandler
|
||||
class TRINITY_DLL_SPEC ChatHandler
|
||||
{
|
||||
public:
|
||||
explicit ChatHandler(WorldSession* session) : m_session(session) {}
|
||||
|
||||
Reference in New Issue
Block a user