Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* npc_ranshalla Escort quest by Joseph*/
- #include "precompiled.h"
- #include "escort_ai.h"
- enum
- {
- QUEST_GUARDIANS = 5,
- SAY_ASD = -1999958
- };
- struct MANGOS_DLL_DECL npc_ranshallaAI : public npc_escortAI
- {
- npc_ranshallAI(Creature* pCreature) : npc_escortAI(pCreature) {Reset();}
- void WaypointReached(uint32 uiPointId)
- {
- switch(uiPointId)
- {
- case 100: DoScriptText(SAY_ASD, m_creature, pPlayer); break;
- }
- }
- };
- bool QuestAccept_npc_ranshalla(Player* pPlayer, Creature* pCreature, const Quest* pQuest)
- {
- if (pQuest->GetQuestId() == QUEST_GUARDIANS)
- {
- pCreature->setFaction(FACTION_ESCORT_N_NEUTRAL_PASSIVE);
- }
- return true;
- }
- CreatureAI* GetAI_npc_ranshalla(Creature* pCreature)
- {
- return new npc_ranshallaAI(pCreature);
- }
- void AddSC_npc_ranshalla()
- {
- Script * newscript;
- newscript = new Script;
- newscript->Name = "npc_ranshalla";
- newscript->GetAI = &GetAI_npc_ranshalla;
- newscript->pQuestAccept = &QuestAccept_npc_ranshalla;
- newscript->RegisterSelf();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement