new QuestTracker(player, active, completed)
Parameters:
Name | Type | Description |
---|---|---|
player |
Player | |
active |
Array | |
completed |
Array |
Properties:
Name | Type | Description |
---|---|---|
player |
Player | |
completedQuests |
Map | |
activeQuests |
Map |
Methods
-
complete(qid)
-
Parameters:
Name Type Description qid
EntityReference -
emit(event, …args)
-
Proxy events to all active quests
Parameters:
Name Type Attributes Description event
string args
* <repeatable>
-
hydrate(state, questData)
-
Parameters:
Name Type Description state
GameState questData
object Data pulled from the pfile
-
isActive(qid) → {boolean}
-
Parameters:
Name Type Description qid
EntityReference Returns:
boolean -
isComplete(qid) → {boolean}
-
Parameters:
Name Type Description qid
EntityReference Returns:
boolean -
serialize() → {object}
-
Returns:
object -
start(quest)
-
Parameters:
Name Type Description quest
Quest