Module:AbilityTable: Difference between revisions

Jump to navigation Jump to search
Vergir (talk | contribs)
Rename abilityPropTable to render; add hide parameter for column hiding (with help from vergir-bot LLM)
Add melee stat using Scale.Type value matching; add human notes for Puddle Punch and Bashdown (with help from vergir-bot LLM)
Line 1: Line 1:
-- Renders sortable wikitables of abilities filtered by a named stat.
-- Renders sortable wikitables of abilities filtered by a named stat.


-- Maps lowercase friendly stat names to internal AbilityData
-- Maps lowercase friendly stat names to internal AbilityData property keys or values.
-- Entries are matched either as key names (property exists with non-zero value)
-- or as plain string values anywhere in the record (e.g. Scale.Type = "melee").
local stat_to_props = {
local stat_to_props = {
     ["charges"] = { "AbilityCharges" },
     ["charges"] = { "AbilityCharges" },
    ["melee"]  = { "melee", "heavy_melee", "light_melee" },
}
}


Line 10: Line 13:
     ["charges"] = {
     ["charges"] = {
         ["Jar of Dead"] = "Charges by being near when anything dies.",
         ["Jar of Dead"] = "Charges by being near when anything dies.",
    },
    ["melee"] = {
        ["Puddle Punch"] = "Upgrades to [[Heavy Melee]] on T3. Can be parried.",
        ["Bashdown"]    = "Counts as [[Light Melee]]. Upgrades to [[Heavy Melee]] on T3.",
     },
     },
}
}