diff options
author | megamage <none@none> | 2008-11-21 19:45:49 -0600 |
---|---|---|
committer | megamage <none@none> | 2008-11-21 19:45:49 -0600 |
commit | fa667cf4507e5635d597b878119ce20f2836cc8c (patch) | |
tree | 34a1b3a70db2d8ba86be680bb341f1e499b0d672 /src/game/QuestHandler.cpp | |
parent | b2ba78e57a7c1895d1bacf950a3705eedd01c256 (diff) |
*Alterac Valley. By Bogie and Balrok. Note: some core contents are modified. Will fix them later. Some sql are disabled because of possible conflict with offical DB. Use them at your own risk.
--HG--
branch : trunk
Diffstat (limited to 'src/game/QuestHandler.cpp')
-rw-r--r-- | src/game/QuestHandler.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/game/QuestHandler.cpp b/src/game/QuestHandler.cpp index 1dbb8e92b38..abb285e6dbb 100644 --- a/src/game/QuestHandler.cpp +++ b/src/game/QuestHandler.cpp @@ -31,6 +31,8 @@ #include "ObjectAccessor.h" #include "ScriptCalls.h" #include "Group.h" +#include "BattleGround.h" +#include "BattleGroundAV.h" void WorldSession::HandleQuestgiverStatusQueryOpcode( WorldPacket & recv_data ) { @@ -401,6 +403,12 @@ void WorldSession::HandleQuestComplete(WorldPacket& recv_data) Quest const *pQuest = objmgr.GetQuestTemplate(quest); if( pQuest ) { + // TODO: need a virtual function + if(GetPlayer()->InBattleGround()) + if(BattleGround* bg = GetPlayer()->GetBattleGround()) + if(bg->GetTypeID() == BATTLEGROUND_AV) + ((BattleGroundAV*)bg)->HandleQuestComplete(quest, GetPlayer()); + if( _player->GetQuestStatus( quest ) != QUEST_STATUS_COMPLETE ) { if( pQuest->IsRepeatable() ) |