Module:HeroData/doc
This is the documentation page for Module:HeroData
This module allows for the dynamic extraction of hero data parameters, technical properties, and translated profiles stored within the wiki's Cargo database (specifically from the Hero and Translation tables). It automatically handles localized fallback to English if a translation in the requested language is missing.
Basic Syntax
To fetch a data field, use the following syntax:
{{#invoke:HeroData|get|HERO_ID|VARIABLE|LANGUAGE_CODE}}
HERO_ID: The technical identifier of the hero (e.g.,dungeon_hero_3).VARIABLE: The keyword for the specific data field you want to display (see the list below).LANGUAGE_CODE: (Optional) The localization code (e.g.,en,fr,pl). Defaults to English (en).
---
Available Variables
📝 Text & Translations (Language-Dependent)
These fields query the Translation table. They dynamically adapt to the requested language code and fallback to English seamlessly if missing.
| Variable | Description | Database Filter Relation |
|---|---|---|
name |
The localized name of the hero. | type="hero"
|
description |
The localized official biography or lore text of the hero. | type="hero"
|
motto |
The hero's localized specific quote or motto. | type="hero_motto"
|
⚔️ Split Starting Skills (Virtual Fields)
Instead of returning a comma-separated string from the database, the module automatically slices the data array into distinct outputs:
| Variable | Description | Fallback Behavior |
|---|---|---|
start_skill_1 |
Returns the technical ID of the hero's primary starting skill. | Always returns the first value found. |
start_skill_2 |
Returns the technical ID of the hero's secondary starting skill. | Returns an empty string ("") if the hero only has one starting skill.
|
⚙️ Core Technical Properties
Standard database values extracted directly from the primary Hero table records.
| Variable | Description | Example Value |
|---|---|---|
class_id |
Pointers linking to the hero's mechanical archetype. | might_dungeon
|
specialization_id |
Points to the unique skill perk assigned to this specific hero unit. | dungeon_hero_3_specialization
|
faction |
The alignment group or city archetype the hero is drafted under. | dungeon
|
---


