Planeshift
Public Member Functions | Public Attributes | Protected Attributes

QuestAssignment Struct Reference

This structure tracks assigned quests. More...

#include <pscharquestmgr.h>

List of all members.

Public Member Functions

csWeakRef< psQuest > & GetQuest ()
 Since "quest" member can be nulled without notice, this accessor function attempts to refresh it if NULL.
bool IsCompleted ()
 Checks if the quest(/step) assignment is marked as complete.
void SetQuest (psQuest *q)

Public Attributes

PID assigner_id
 Character id of player who assigned quest to this player. This is used to make sure you cannot get two quests from the same guy at the same time.
unsigned int completionOrder
 In case this questassignment was completed it will contain the order of completion.
bool dirty
 Dirty flag determines minimal save on exit.
int last_response
 To avoid losing a chain of responses in a quest, last responses are stored per assigned quest.
PID last_response_from_npc_pid
 To avoid losing a chain of responses in a quest, last responses are stored per assigned quest.
unsigned long lockout_end
 When a quest is completed, often it cannot immediately be repeated. This indicate the time when it can be started again.
char status
 This status determines whether the quest was assigned, completed, or is marked for deletion.

Protected Attributes

csWeakRef< psQuestquest
 Weak pointer to the underlying quest relevant here.
int quest_id
 Quest ID saved in case quest gets nulled out from us.

Detailed Description

This structure tracks assigned quests.

Definition at line 48 of file pscharquestmgr.h.


Member Function Documentation

csWeakRef<psQuest>& QuestAssignment::GetQuest ( )

Since "quest" member can be nulled without notice, this accessor function attempts to refresh it if NULL.

bool QuestAssignment::IsCompleted ( )

Checks if the quest(/step) assignment is marked as complete.

Returns:
True if the quest assignment is marked as complete.
void QuestAssignment::SetQuest ( psQuest q)

Member Data Documentation

Character id of player who assigned quest to this player. This is used to make sure you cannot get two quests from the same guy at the same time.

Definition at line 51 of file pscharquestmgr.h.

In case this questassignment was completed it will contain the order of completion.

Definition at line 64 of file pscharquestmgr.h.

Dirty flag determines minimal save on exit.

Definition at line 55 of file pscharquestmgr.h.

To avoid losing a chain of responses in a quest, last responses are stored per assigned quest.

Definition at line 59 of file pscharquestmgr.h.

To avoid losing a chain of responses in a quest, last responses are stored per assigned quest.

Definition at line 61 of file pscharquestmgr.h.

When a quest is completed, often it cannot immediately be repeated. This indicate the time when it can be started again.

Definition at line 57 of file pscharquestmgr.h.

csWeakRef<psQuest> QuestAssignment::quest [protected]

Weak pointer to the underlying quest relevant here.

Definition at line 83 of file pscharquestmgr.h.

Quest ID saved in case quest gets nulled out from us.

Definition at line 80 of file pscharquestmgr.h.

This status determines whether the quest was assigned, completed, or is marked for deletion.

Definition at line 53 of file pscharquestmgr.h.


The documentation for this struct was generated from the following file: