Databases

From RPG Creation Kit
Revision as of 18:38, 6 March 2022 by Silvematt (talk | contribs) (Created page with "Databases are assets that contains a collection of elements stored by IDs. Databases are the way Dialogues, Items, Behaviours and other elements are retrieved by ID while the game is running. Whenever we want to add an item to an inventory, or change the Dialogue of an NPC, or get and spawn an NPC in the first place, we are allowed to do that thanks to the Databases. There are 9 types of databases, each of one contains their own collection of elements. * '''AI Databas...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Databases are assets that contains a collection of elements stored by IDs. Databases are the way Dialogues, Items, Behaviours and other elements are retrieved by ID while the game is running. Whenever we want to add an item to an inventory, or change the Dialogue of an NPC, or get and spawn an NPC in the first place, we are allowed to do that thanks to the Databases.

There are 9 types of databases, each of one contains their own collection of elements.

  • AI Database
  • Behaviours Database
  • Dialogues Database
  • Factions Database
  • Icons Database
  • Quests Database
  • Race Database
  • Worldspace Database


You can get an element inside a database by referencing to the database type and by calling the GetItem(...) functionl

Example, I want to retrieve to retrieve at runtime the Item "Iron Curiass", that has as ID "IronCuriass001":


Item curiass = ItemsDatabase.GetItem("IronCuriass001");

Updating the Databases

Updating the databases is the process of finding and inserting inside the Databases new entries, that were added by the user. Whenever you create a new item, a new Dialogue or any new element listed in the Databases Lists above, you need to update the databases.

To do that, click on the toolbar "RPG Creation Kit -> Update all Databases", a short loading will take place, and after that if the console doesn't display any errors, the databases have been updated.

Db1.png