diff --git a/src/core/game3/battle/abilities.lua b/src/core/game3/battle/abilities.lua index 2cfa4357..5d7e7d4c 100644 --- a/src/core/game3/battle/abilities.lua +++ b/src/core/game3/battle/abilities.lua @@ -8,9 +8,11 @@ local Abilities = {} -- pokefirered/src/data/text/abilities.h:162 local DISPLAY = { COMPOUND_EYES = "COMPOUNDEYES", LIGHTNING_ROD = "LIGHTNINGROD" } +-- The name battle messages print. No registry renames abilities, so a +-- translation reaches them through Strings(), keyed by the cart's English. function Abilities.name(ab) if not ab then return "" end - return DISPLAY[ab] or (ab:gsub("_", " ")) + return Strings(DISPLAY[ab] or (ab:gsub("_", " "))) end -- pokefirered/src/battle_util.c:31 diff --git a/src/ui/game3/summary_menu.lua b/src/ui/game3/summary_menu.lua index b59b1777..db42c758 100644 --- a/src/ui/game3/summary_menu.lua +++ b/src/ui/game3/summary_menu.lua @@ -583,7 +583,8 @@ local function draw_page_skills(mon) end ability = ability or "—" local ax, ay = cxy("abilityName", 74, 129) - draw_text(tostring(ability), ax, ay, 80, "NORMAL") + -- No registry renames abilities; a translation reaches the name through Strings(). + draw_text(Strings(tostring(ability)), ax, ay, 80, "NORMAL") local desc = SummaryData.abilityDescription(abilityId, tostring(ability)) local ad = coords().abilityDesc or { x = 10, y = 143, w = 232 } draw_text(desc, ad.x or 10, ad.y or 143, ad.w or 232, "NORMAL")