Module:Icon/doc: Difference between revisions

From The Deadlock Wiki
Jump to navigation Jump to search
mNo edit summary
m mc
Line 8: Line 8:
An additional resource for other icons can be found at [[Data:ResourceLookup2.json]], a manually maintained table used for other icons; some entries may rely on a dictionary key.
An additional resource for other icons can be found at [[Data:ResourceLookup2.json]], a manually maintained table used for other icons; some entries may rely on a dictionary key.


See also: [[Module:Icon/data]]
See [[Module:Icon/data]] for manual overrides, legacy items, aliases, and renames used by this module.


== Usage ==
== Usage ==
Any of the following templates work for any icon type. The module auto-detects the type:
Any of the following templates can be used. The module automatically detects the icon type:
* {{tl|HeroIcon}}
* {{tl|HeroIcon}}
* {{tl|AbilityIcon}}
* {{tl|AbilityIcon}}
Line 17: Line 17:
* {{tl|EntityIcon}}
* {{tl|EntityIcon}}


'''Note:''' While all four templates work identically, it is recommended to use the correct template (e.g., use <nowiki>{{AbilityIcon|Siphon Life}}</nowiki> for clarity even though <nowiki>{{HeroIcon|Siphon Life}}</nowiki> will work).
'''Note:''' While all four templates work identically, it is recommended to use the appropriate one for clarity (e.g., use <nowiki>{{AbilityIcon|Siphon Life}}</nowiki> even though <nowiki>{{HeroIcon|Siphon Life}}</nowiki> will also work).


== Error tracking ==
== Error tracking ==
Icons that fail to render are added to [[:Category:Module:Icon ERROR]].
Icons that fail to render are added to [[:Category:Module:Icon ERROR]].
<includeonly>[[Category:Modules]]</includeonly><noinclude>[[Category:Module documentation]]</noinclude>
<includeonly>[[Category:Modules]]</includeonly><noinclude>[[Category:Module documentation]]</noinclude>

Revision as of 22:39, 17 May 2026

Main module for rendering game icons.

Note: This module is not intended for direct use. Use the templates below.

Data sources

The module reads from Data:ResourceLookup.json, a pre-indexed lookup table generated by Deadbot at deploy time. When the bot uploads new game files, icons update automatically.

An additional resource for other icons can be found at Data:ResourceLookup2.json, a manually maintained table used for other icons; some entries may rely on a dictionary key.

See Module:Icon/data for manual overrides, legacy items, aliases, and renames used by this module.

Usage

Any of the following templates can be used. The module automatically detects the icon type:

Note: While all four templates work identically, it is recommended to use the appropriate one for clarity (e.g., use {{AbilityIcon|Siphon Life}} even though {{HeroIcon|Siphon Life}} will also work).

Error tracking

Icons that fail to render are added to Category:Module:Icon ERROR.