Add Optional Enforce Task Level Requirement

Affected:
quest::assigntask
$client->AssignTask

This is to allow those task level requirements in DB to be used,
optionally. It defaults to do not enforce (translated: no change for
current servers), but can be set with an additional flag to both
commands (see below). The LUA bit was added thanks to help from demonstar55.

quest::assigntask(703); # works
quest::assigntask(703, 1); # denies user
$client->AssignTask(701, $npc->GetID()); # works
$client->AssignTask(701, $npc->GetID(), 1); # denies user
This commit is contained in:
hateborne
2015-07-15 19:16:51 -04:00
parent 3cd474e960
commit d64f79cb2a
9 changed files with 69 additions and 15 deletions
+1
View File
@@ -242,6 +242,7 @@ public:
int FindSpellBookSlotBySpellID(int spell_id);
void UpdateTaskActivity(int task, int activity, int count);
void AssignTask(int task, int npc_id);
void AssignTask(int task, int npc_id, bool enforce_level_requirement);
void FailTask(int task);
bool IsTaskCompleted(int task);
bool IsTaskActive(int task);