Template:HeroInfoBox: Difference between revisions
From Heroes of Might and Magic: Olden Era Official Wiki
No edit summary |
No edit summary |
||
| Line 1: | Line 1: | ||
<includeonly> | <noinclude> | ||
{{loc}} | |||
This template is the intended means of summoning an infobox for Heroes on their individual pages. Provide the internal ID of the hero associated with that page, provide the language, and the result will be filled in using data from [[Help:Cargo|Cargo]]. | |||
{{Template:HeroInfoBox|lang=en|id=demon_hero_4}} | |||
<code><nowiki>{{Template:HeroInfoBox|lang=en|id=demon_hero_4}}</nowiki></code> | |||
{{clear}} | |||
</noinclude><includeonly> | |||
{{#cargo_query:tables=Hero=H,HeroClass=HC,Faction=F | {{#cargo_query:tables=Hero=H,HeroClass=HC,Faction=F | ||
|join on=H.class_id=HC.id,H.faction=F.id | |join on=H.class_id=HC.id,H.faction=F.id | ||
|fields= H.name, H.motto, H.description=biography, H.name_sid, H.motto_sid, H.desc_sid, HC.name=class, F.name=faction, H.class_type, H.icon, H.specialization_id, H.source_path, H.start_skills, H.start_skill_levels, H.start_magics, H.cost_gold, H.start_level, H.attacks_times_before, H.mesh, H.mount, H.native_biome, H.skills_roll_variant, H.view_radius, H.stats_num, H.magic_casts_per_round, H.enable_tactics, H.tactics_placement_size, H.enable_hero_native_biome, | |fields= H.id=id, H.name, H.motto, H.description=biography, H.name_sid, H.motto_sid, H.desc_sid, HC.name=class, F.name=faction, H.class_type, H.icon, H.specialization_id, H.source_path, H.start_skills=start_skills, H.start_skill_levels, H.start_magics, H.cost_gold, H.start_level, H.attacks_times_before, H.mesh, H.mount, H.native_biome, H.skills_roll_variant, H.view_radius, H.stats_num, H.magic_casts_per_round, H.enable_tactics, H.tactics_placement_size, H.enable_hero_native_biome, | ||
IF(H.offence IS NULL, HC.offence, H.offence)=startattack, | IF(H.offence IS NULL, HC.offence, H.offence)=startattack, | ||
IF(H.defence IS NULL, HC.defence, H.defence)=startdefense, | IF(H.defence IS NULL, HC.defence, H.defence)=startdefense, | ||
| Line 14: | Line 26: | ||
|delimiter=\n | |delimiter=\n | ||
}} | }} | ||
</includeonly> | </includeonly> | ||
Revision as of 03:32, 14 May 2026
This template is the intended means of summoning an infobox for Heroes on their individual pages. Provide the internal ID of the hero associated with that page, provide the language, and the result will be filled in using data from Cargo.
Error: No field named "name" found for the database table "Hero".
{{Template:HeroInfoBox|lang=en|id=demon_hero_4}}


