Module:Abilities/utils: Difference between revisions

corrected example call for find_hero_by_ability
No edit summary
Line 34: Line 34:
-- Check each ability for this hero
-- Check each ability for this hero
for ability_num, ability in pairs(ui_data) do
for ability_num, ability in pairs(ui_data) do
local current_name = Lang.get_string(ability.Key)
local current_name = lang.get_string(ability.Key)
if current_name == ability_name then
if current_name == ability_name then
return hero_key
return hero_key