Codechange: Use GetString() with local parameters in script functions. (#13585)

This commit is contained in:
Peter Nelson
2025-02-16 21:27:25 +00:00
committed by GitHub
parent fd4adc55e3
commit 154896ce55
18 changed files with 19 additions and 39 deletions

View File

@@ -72,8 +72,7 @@
{
if (!IsValidGroup(group_id)) return std::nullopt;
::SetDParam(0, group_id);
return GetString(STR_GROUP_NAME);
return ::StrMakeValid(::GetString(STR_GROUP_NAME, group_id));
}
/* static */ bool ScriptGroup::SetParent(GroupID group_id, GroupID parent_group_id)