mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-23 13:46:24 +00:00
fix(quest): fix some quest chains + align NextQuestID with TC (#1351)
This commit is contained in:
@@ -4528,16 +4528,13 @@ void ObjectMgr::LoadQuests()
|
||||
|
||||
if (qinfo->NextQuestId)
|
||||
{
|
||||
QuestMap::iterator qNextItr = _questTemplates.find(abs(qinfo->GetNextQuestId()));
|
||||
QuestMap::iterator qNextItr = _questTemplates.find(qinfo->GetNextQuestId());
|
||||
if (qNextItr == _questTemplates.end())
|
||||
{
|
||||
sLog->outErrorDb("Quest %d has NextQuestId %i, but no such quest", qinfo->GetQuestId(), qinfo->GetNextQuestId());
|
||||
sLog->outErrorDb("Quest %d has NextQuestId %u, but no such quest", qinfo->GetQuestId(), qinfo->GetNextQuestId());
|
||||
}
|
||||
else
|
||||
{
|
||||
int32 signedQuestId = qinfo->NextQuestId < 0 ? -int32(qinfo->GetQuestId()) : int32(qinfo->GetQuestId());
|
||||
qNextItr->second->prevQuests.push_back(signedQuestId);
|
||||
}
|
||||
qNextItr->second->prevQuests.push_back(static_cast<int32>(qinfo->GetQuestId()));
|
||||
}
|
||||
|
||||
if (qinfo->ExclusiveGroup)
|
||||
|
||||
@@ -154,7 +154,7 @@ void Quest::LoadQuestTemplateAddon(Field* fields)
|
||||
RequiredClasses = fields[2].GetUInt32();
|
||||
SourceSpellid = fields[3].GetUInt32();
|
||||
PrevQuestId = fields[4].GetInt32();
|
||||
NextQuestId = fields[5].GetInt32();
|
||||
NextQuestId = fields[5].GetUInt32();
|
||||
ExclusiveGroup = fields[6].GetInt32();
|
||||
RewardMailTemplateId = fields[7].GetUInt32();
|
||||
RewardMailDelay = fields[8].GetUInt32();
|
||||
|
||||
@@ -230,7 +230,7 @@ class Quest
|
||||
uint32 GetSuggestedPlayers() const { return SuggestedPlayers; }
|
||||
uint32 GetTimeAllowed() const { return TimeAllowed; }
|
||||
int32 GetPrevQuestId() const { return PrevQuestId; }
|
||||
int32 GetNextQuestId() const { return NextQuestId; }
|
||||
uint32 GetNextQuestId() const { return NextQuestId; }
|
||||
int32 GetExclusiveGroup() const { return ExclusiveGroup; }
|
||||
uint32 GetNextQuestInChain() const { return RewardNextQuest; }
|
||||
uint32 GetCharTitleId() const { return RewardTitleId; }
|
||||
@@ -371,7 +371,7 @@ class Quest
|
||||
uint32 RequiredClasses = 0;
|
||||
uint32 SourceSpellid = 0;
|
||||
int32 PrevQuestId = 0;
|
||||
int32 NextQuestId = 0;
|
||||
uint32 NextQuestId = 0;
|
||||
int32 ExclusiveGroup = 0;
|
||||
uint32 RewardMailTemplateId = 0;
|
||||
uint32 RewardMailDelay = 0;
|
||||
|
||||
Reference in New Issue
Block a user