BaseQuestObjective
BaseQuestObjective Detailled Documentation
Its the parent class that represent the objective itself. It is instancied when the Objective is active. It contains the logic to run the objective based on the ObjectiveFragment. You can see two examples of this class in the Demo Content.
To make the objective work you need to override the ActivateObjective function to handle the logic.
API
Functions
InitializeObjective
public
Initialize objective with the objective fragment and the actor responsible for this objective
GetProgress
public
returns a float that represents the current progress (e.g. if we kill 2 monsters out of 3, the float would be 0.67)
ActivateObjective
public
Activate the objective. This is called after the objective has been instantiated and must be overriden in BP class to handle the logic
DeactivateObjective
public
Deactivate the objective
GetCurrentProgressFormat
public
Returns a string that represents the progress format that is displayed on the hud. (e.g. "Monsters killed: 2/3")
GetQuestObjectiveData
public
returns the objective fragment for this objective
GetObjectiveRewards
public
returns the rewards of this objective
GetIsOptional
public
Returns weither the objective is optional
UpdateProgress
protected
Broadcast the event dispatcher OnProgressChanged
CompleteObjective
protected
Change the state and broadcast the OnCompleted event dispatcher
Event Dispatchers
OnCompleted
Is called when the objective is complete
OnProgressChanged
Is called when the progress changed
Variables
CurrentState
protected
The state of the objective (NotStarted, InProgress, Completed)
QuestManager
protected
Ref to the quest manager as we can't access it directly by calling the usual GetQuestManagerSubsytem function
QuestObjectiveData
protected
Ref to the objective fragment
ObjectiveOwner
protected
Ref to the owner of the objective
ObjectiveRewards
protected
Array of rewards
Last updated