Module:Utilities/doc: Difference between revisions
Jump to navigation
Jump to search
m get_slot_color trying an example with debug_mode |
m moving examples to SlotColor |
||
(2 intermediate revisions by the same user not shown) | |||
Line 5: | Line 5: | ||
==get_slot_color== | ==get_slot_color== | ||
Retrieve's the | Retrieve's the color of a certain slot/category in any color format (default hex), formerly known in english as Weapon, Vitality, and Spirit, though their unlocalized names are Weapon, Armor, and Tech. Utilized by [[Template:SlotColor]] | ||
===Parameters=== | ===Parameters=== | ||
* '''slot''' - slot key, options are Weapon, Armor, and Tech | * '''slot''' - slot key, options are Weapon, Armor, and Tech | ||
* '''color_format''' - color format | * '''color_format''' - color format - Defaults to hex. Valid options are hex, rgb, hsl, cmyk | ||
* '''no_wrap''' - (OPTIONAL) - Defaults to false. Set to true to remove prefixes and postfixes of '#' from hex, or 'rgb()', 'hsl()', and 'cmyk()' from the other formats. May be useful for altering the values dynamically | |||
* '''debug_mode''' - (OPTIONAL) - Defaults to false. Used mostly for documentation purposes | |||
===Examples=== | ===Examples=== | ||
See examples at [[Template:SlotColor]] | |||
Latest revision as of 22:47, 1 November 2024
Overview[edit source]
Utility functions that serve any miscellaneous purpose
Functions[edit source]
get_slot_color[edit source]
Retrieve's the color of a certain slot/category in any color format (default hex), formerly known in english as Weapon, Vitality, and Spirit, though their unlocalized names are Weapon, Armor, and Tech. Utilized by Template:SlotColor
Parameters[edit source]
- slot - slot key, options are Weapon, Armor, and Tech
- color_format - color format - Defaults to hex. Valid options are hex, rgb, hsl, cmyk
- no_wrap - (OPTIONAL) - Defaults to false. Set to true to remove prefixes and postfixes of '#' from hex, or 'rgb()', 'hsl()', and 'cmyk()' from the other formats. May be useful for altering the values dynamically
- debug_mode - (OPTIONAL) - Defaults to false. Used mostly for documentation purposes
Examples[edit source]
See examples at Template:SlotColor