API:GetQuestRequest

Returns information about quests and their goals.

GetQuestRequest(index,arg2)

Arguments

 *  index
 * The quest index number. possible values 1 to 30


 *  arg2
 * The value returned depends on this value.

Returns
Returned information depends on the value given by 'arg2'.

note

 * The number of goals is not the number of items. If you have to collect 10 of one item then that is 1 goal.

Example
Untested function GetGoals(questID) questInfo = {} questInfo.level = GetQuestRequest(questID,-3) -- The level of the quest questInfo.name = GetQuestRequest(questID,-2) -- The name of the quest questInfo.goalnumber = GetQuestRequest(questID,-1) -- Number of goals to complete quest for i = 1, questInfo.goalnumber do -- For each goal get name and status questInfo[i] = {} questInfo[i].goalname, questInfo[i].goalstatus = GetQuestRequest(questID,i) end

return questInfo -- Return object with quest info end