1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-20 05:23:04 +01:00

Use correct language for scan-objects

This commit is contained in:
Ted John
2018-04-27 18:23:39 +01:00
parent 238079ef7f
commit 7075f6ca25
8 changed files with 38 additions and 9 deletions

View File

@@ -101,6 +101,18 @@ std::string StringTable::GetString(uint8 id) const
return std::string();
}
std::string StringTable::GetString(uint8 language, uint8 id) const
{
for (auto &string : _strings)
{
if (string.LanguageId == language && string.Id == id)
{
return string.Text;
}
}
return std::string();
}
void StringTable::SetString(uint8 id, uint8 language, const std::string &text)
{
StringTableEntry entry;