* Added new specialflag in quest_template for auto-accept quests.
* SpecialFlags|4 * After much research it was determined that blizz does this serverside. --HG-- branch : trunk
This commit is contained in:
@@ -13904,7 +13904,7 @@ void Player::SendPreparedQuest(uint64 guid)
|
||||
return;
|
||||
}
|
||||
|
||||
if (pQuest->HasFlag(QUEST_FLAGS_AUTO_ACCEPT) && CanAddQuest(pQuest, true))
|
||||
if (pQuest->HasFlag(QUEST_TRINITY_FLAGS_AUTO_ACCEPT) && CanAddQuest(pQuest, true))
|
||||
{
|
||||
AddQuest(pQuest, pObject);
|
||||
if (CanCompleteQuest(quest_id))
|
||||
|
||||
@@ -141,11 +141,13 @@ enum __QuestFlags
|
||||
QUEST_FLAGS_AUTOCOMPLETE = 0x00010000, // auto complete
|
||||
QUEST_FLAGS_UNK5 = 0x00020000, // has something to do with ReqItemId and SrcItemId
|
||||
QUEST_FLAGS_UNK6 = 0x00040000, // use Objective text as Complete text
|
||||
QUEST_FLAGS_AUTO_ACCEPT = 0x00080000, // quests in starting areas
|
||||
QUEST_FLAGS_UNK7 = 0x00080000, // quests in starting areas
|
||||
|
||||
// Trinity flags for set SpecialFlags in DB if required but used only at server
|
||||
QUEST_TRINITY_FLAGS_REPEATABLE = 0x00100000, // Set by 1 in SpecialFlags from DB
|
||||
QUEST_TRINITY_FLAGS_EXPLORATION_OR_EVENT = 0x00200000, // Set by 2 in SpecialFlags from DB (if reequired area explore, spell SPELL_EFFECT_QUEST_COMPLETE casting, table `*_script` command SCRIPT_COMMAND_QUEST_EXPLORED use, set from script)
|
||||
QUEST_TRINITY_FLAGS_AUTO_ACCEPT = 0x00400000, // Set by 4 in SpecialFlags in DB if the quest is to be auto-accepted.
|
||||
|
||||
QUEST_TRINITY_FLAGS_DB_ALLOWED = 0xFFFFF | QUEST_TRINITY_FLAGS_REPEATABLE | QUEST_TRINITY_FLAGS_EXPLORATION_OR_EVENT,
|
||||
|
||||
// Trinity flags for internal use only
|
||||
@@ -244,7 +246,7 @@ class Quest
|
||||
bool IsDaily() const { return QuestFlags & QUEST_FLAGS_DAILY; }
|
||||
bool IsWeekly() const { return QuestFlags & QUEST_FLAGS_WEEKLY; }
|
||||
bool IsDailyOrWeekly() const { return QuestFlags & (QUEST_FLAGS_DAILY | QUEST_FLAGS_WEEKLY); }
|
||||
bool IsAutoAccept() const { return QuestFlags & QUEST_FLAGS_AUTO_ACCEPT; }
|
||||
bool IsAutoAccept() const { return QuestFlags & QUEST_TRINITY_FLAGS_AUTO_ACCEPT; }
|
||||
bool IsRaidQuest() const { return Type == QUEST_TYPE_RAID || Type == QUEST_TYPE_RAID_10 || Type == QUEST_TYPE_RAID_25; }
|
||||
bool IsAllowedInRaid() const;
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
#include "CompilerDefs.h"
|
||||
#include "DBCStructure.h"
|
||||
#include "ConfigEnv.h"
|
||||
#include "SpellScript.h"
|
||||
|
||||
|
||||
class Player;
|
||||
class Creature;
|
||||
|
||||
@@ -246,7 +246,7 @@ void WorldSession::HandleQuestgiverQueryQuestOpcode(WorldPacket & recv_data)
|
||||
Quest const* pQuest = objmgr.GetQuestTemplate(quest);
|
||||
if (pQuest)
|
||||
{
|
||||
if (pQuest->HasFlag(QUEST_FLAGS_AUTO_ACCEPT) && _player->CanAddQuest(pQuest, true))
|
||||
if (pQuest->HasFlag(QUEST_TRINITY_FLAGS_AUTO_ACCEPT) && _player->CanAddQuest(pQuest, true))
|
||||
{
|
||||
_player->AddQuest(pQuest, pObject);
|
||||
if (_player->CanCompleteQuest(quest))
|
||||
|
||||
Reference in New Issue
Block a user