Facts

Fact is pair of variables: FactID (string) and value (integer number).
Facts are commonly used to save important gameplay informations. Facts are accessible globally.

Example fact
FactID: q001_aryan_killed
Value: 1

Systems using facts:
  • quests
  • dialogs
  • scripts
  • engine functions

Common use cases

  • Player's choice in quest is saved to fact. You can check value of this fact anytime, so you can trigger consequences of choice in following quest.
  • Progress in quest is saved to fact. You can check this fact in dialog - new conversation options are available if fact exists.
  • Facts are added while executing gameplay scripts, i.e. hitting object with Aard sign. If fact is added, quest is progressing.


Adding fact

Quest

1. In the quest, insert block FactsDB Change (in Game System Control group).
2. Properties will appears, with two options: FactID - here write name of the fact (i.e. "q01_nekkers_killed") and Value - 1. Usually value equals to 1 means that "fact is true". But it's just convention - you can set any other value.
3. Fact should be added after fulfilling a certain condition. In this case - after killing nekkers.

Scene


Script


Checking fact

Quest

Facts are usually checked in order to progress with the quest. It can be done by a Pause CQuestFactsDBCondition.

1. In properties, in FactID write the name of the fact (killing monsters) and in Value - 1 (true).
2. When fact will be fulfilled the Pause will release signal and activate the context dialogue.

Scene


Script