Skip to content

DatabaseResource ​

Inherits: Resource

Inherited by: AbilityDefinition, Affix, ArmorClassDefinition, Conversation, CraftSchoolDefinition, CraftingRecipeDefinition, CurrencyDefinition, DamageTypeDefinition, DynamicMusic, Effect, EmoteDefinition, EntityDefinition, EntityTagDefinition, EnvironmentConfig, EquipmentSlotDefinition, EquipmentTypeDefinition, Event, FactionDefinition, GlobalVariable, GroupDefinition, GrowthProfile, ImmunityDefinition, InteractableDefinition, ItemDefinition, LootTable, ModularBehaviorScript, ModularCombatScript, MountDefinition, PlayerClassDefinition, PoolDefinition, PopupData, ProficiencyDefinition, Quality, QuestLine, Quest, SchoolTypeDefinition, SetBonusDefinition, ShelterProfile, SkillPointPool, SkillTree, SkyConfig, SocketDefinition, SoundAlbum, SpawnTableDefinition, StatDefinition, StatGroupDefinition, StatusEffectDefinition, SunConfig, TimeConfig, TrainerDefinition, TriggerAreaData, TriggerTagDefinition, UITagDefinition, UniqueEncounterData, UniqueEntityData, UniqueInteractableData, UniqueSpawnerData, VendorDefinition, WeaponClassDefinition, WeaponProfile, WeatherConfig, WeatherTable, WorldData, ZoneDefinition

The base of everything the database stores. A DatabaseResource has an id, a name, an icon and a description; the id is what other resources use to refer to it.

Description ​

Every resource of the REGISTRY of the Database extends this class: abilities, effects, NPCs, items, quests, factions, stats, vendors, popups and so on. It is saved as the file <id>.tres in the folder of its type under res://src/data/.

Properties ​

intid
Stringdisplay_name"":
CompressedTexture2Dicon
Stringdescription"":

Property descriptions ​

int id ​

Unique identifier for this entity

String display_name = "": ​

Display name shown in UI and nameplates. Reading it gives the translation when the game is played in another language (see Localization); the editor and saves read the stored text

CompressedTexture2D icon ​

Icon displayed in UI elements

String description = "": ​

Optional description or background. Reading it gives the translation when the game is played in another language (see Localization)