Your Quest Condition
v4.0
Last updated
v4.0
Last updated
Creating a custom Quest Condition which can be easily managed in the Inspector is not that difficult. You will create three scripts, starting with one that inherits from QuestCondition
.
Create a script which looks like this, but name it appropriately for your condition. The class in the image below is called BlackboardValueBool
indicating that the quest condition may be completed if the bool
value
from a Blackboard
note is true
or false
-- all things to determine once we create the object!
Change the default filename in the CreateAssetMenu
line. Then, change the menuName
path as well. You can choose to put your creation button in the same Game Modules/Quest Condition/[Name Here]
, or customize the path.
The class inherits from QuestCondition
, so the ConditionMet()
method is required. You will customize this script later. For now, lets finish creating the other two scripts.
This method is what does the actual work. This is where you will determine whether the condition has been met or not, and return true if it has been.
Refer to the existing QuestConditions
to see how those have been created.