aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Entities
diff options
context:
space:
mode:
authorIntel <chemicstry@gmail.com>2014-12-28 23:33:26 +0200
committerIntel <chemicstry@gmail.com>2014-12-28 23:33:26 +0200
commitce8102cf8ddbfac4fd96eca4a79848027db03ab3 (patch)
treea6a0b7ea6f9601ea6f669deed029b1adb4e3805e /src/server/game/Entities
parentf09217ec046ca990bd6c3e78d7357287a393617a (diff)
Core/Quests: Fixed index typos and added some missing data to quest query packet
Diffstat (limited to 'src/server/game/Entities')
-rw-r--r--src/server/game/Entities/Creature/GossipDef.cpp6
-rw-r--r--src/server/game/Entities/Player/Player.cpp6
2 files changed, 9 insertions, 3 deletions
diff --git a/src/server/game/Entities/Creature/GossipDef.cpp b/src/server/game/Entities/Creature/GossipDef.cpp
index f55174f3232..0f10266b39b 100644
--- a/src/server/game/Entities/Creature/GossipDef.cpp
+++ b/src/server/game/Entities/Creature/GossipDef.cpp
@@ -453,6 +453,7 @@ void PlayerMenu::SendQuestQueryResponse(Quest const* quest) const
std::string questLogTitle = quest->GetLogTitle();
std::string questLogDescription = quest->GetLogDescription();
std::string questDescription = quest->GetQuestDescription();
+ std::string areaDescription = quest->GetAreaDescription();
std::string questCompletionLog = quest->GetQuestCompletionLog();
std::string portraitGiverText = quest->GetPortraitGiverText();
std::string portraitGiverName = quest->GetPortraitGiverName();
@@ -473,6 +474,7 @@ void PlayerMenu::SendQuestQueryResponse(Quest const* quest) const
ObjectMgr::GetLocaleString(localeData->LogTitle, locale, questLogTitle);
ObjectMgr::GetLocaleString(localeData->LogDescription, locale, questLogDescription);
ObjectMgr::GetLocaleString(localeData->QuestDescription, locale, questDescription);
+ ObjectMgr::GetLocaleString(localeData->AreaDescription, locale, areaDescription);
ObjectMgr::GetLocaleString(localeData->QuestCompletionLog, locale, questCompletionLog);
ObjectMgr::GetLocaleString(localeData->PortraitGiverText, locale, portraitGiverText);
ObjectMgr::GetLocaleString(localeData->PortraitGiverName, locale, portraitGiverName);
@@ -499,6 +501,8 @@ void PlayerMenu::SendQuestQueryResponse(Quest const* quest) const
packet.Info.SuggestedGroupNum = quest->GetSuggestedPlayers();
packet.Info.RewardNextQuest = quest->GetNextQuestInChain();
packet.Info.RewardXPDifficulty = quest->GetXPDifficulty();
+ packet.Info.Float10 = quest->Float10; // Unk
+ packet.Info.Float13 = quest->Float13; // Unk
if (quest->HasFlag(QUEST_FLAGS_HIDDEN_REWARDS))
packet.Info.RewardMoney = quest->GetRewMoney();
@@ -555,7 +559,9 @@ void PlayerMenu::SendQuestQueryResponse(Quest const* quest) const
packet.Info.LogTitle = questLogTitle;
packet.Info.LogDescription = questLogDescription;
packet.Info.QuestDescription = questDescription;
+ packet.Info.AreaDescription = areaDescription;
packet.Info.QuestCompletionLog = questCompletionLog;
+ packet.Info.AllowableRaces = quest->GetAllowableRaces();
for (uint32 i = 0; i < quest->Objectives.size(); ++i)
{
diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp
index 99b9cc42159..71c83154307 100644
--- a/src/server/game/Entities/Player/Player.cpp
+++ b/src/server/game/Entities/Player/Player.cpp
@@ -15816,7 +15816,7 @@ void Player::ItemAddedQuestCheck(uint32 entry, uint32 count)
for (uint8 j = 0; j < qInfo->Objectives.size(); ++j)
{
- if (qInfo->Objectives[i].Type != QUEST_OBJECTIVE_ITEM)
+ if (qInfo->Objectives[j].Type != QUEST_OBJECTIVE_ITEM)
continue;
uint32 reqItem = qInfo->Objectives[j].ObjectID;
@@ -15860,7 +15860,7 @@ void Player::ItemRemovedQuestCheck(uint32 entry, uint32 count)
for (uint8 j = 0; j < qInfo->Objectives.size(); ++j)
{
- if (qInfo->Objectives[i].Type != QUEST_OBJECTIVE_ITEM)
+ if (qInfo->Objectives[j].Type != QUEST_OBJECTIVE_ITEM)
continue;
uint32 reqItem = qInfo->Objectives[j].ObjectID;
@@ -16212,7 +16212,7 @@ bool Player::HasQuestForItem(uint32 itemid) const
// This part for ReqItem drop
for (uint8 j = 0; j < qInfo->Objectives.size(); ++j)
{
- if (qInfo->Objectives[i].Type == QUEST_OBJECTIVE_ITEM && itemid == uint32(qInfo->Objectives[i].ObjectID) && q_status.ObjectiveData[j] < qInfo->Objectives[j].Amount)
+ if (qInfo->Objectives[j].Type == QUEST_OBJECTIVE_ITEM && itemid == uint32(qInfo->Objectives[j].ObjectID) && q_status.ObjectiveData[j] < qInfo->Objectives[j].Amount)
return true;
}
// This part - for ReqSource