mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
[10520] Implement CONDITION_QUEST_NONE
For case when need check that quest not taken and not completed in past. Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
parent
5d8cd04f97
commit
9f2e36c7f0
3 changed files with 10 additions and 2 deletions
|
|
@ -8108,6 +8108,12 @@ bool PlayerCondition::Meets(Player const * player) const
|
|||
}
|
||||
return false;
|
||||
}
|
||||
case CONDITION_QUEST_NONE:
|
||||
{
|
||||
if (!player->IsCurrentQuest(value1) && !player->GetQuestRewardStatus(value1))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
|
|
@ -8219,6 +8225,7 @@ bool PlayerCondition::IsValid(ConditionType condition, uint32 value1, uint32 val
|
|||
case CONDITION_QUESTREWARDED:
|
||||
case CONDITION_QUESTTAKEN:
|
||||
case CONDITION_QUESTAVAILABLE:
|
||||
case CONDITION_QUEST_NONE:
|
||||
{
|
||||
Quest const *Quest = sObjectMgr.GetQuestTemplate(value1);
|
||||
if (!Quest)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue