• Our friends from AlphaCentauri2.info are in need of technical assistance. If you have experience with the LAMP stack and some hours to spare, please help them out and post here.

{1_civ[3]} doesn't work in mods

skalozubio

Chieftain
Joined
Dec 30, 2021
Messages
12
Hello.
I'm making a mod, where I translate other mods to russian language.
In russian localization we use 6 forms of 'cases' for each name.
For example:
<Replace Tag="LOC_CIVILIZATION_RUSSIA_NAME" Language="ru_RU">
<Text>Россия|России|России|Россию|Россией|России</Text>
<Gender>feminine</Gender>
<Plurality>1</Plurality>
</Replace>
It means the word "Russia" has 6 forms and I can use any of them.
When I write {1_civ[3]}, the result will be - "России"
It works pretty well everywhere in the game.
But it doesn't work in the mods.
Have you any idea why?
 
All works well. Just mod's authors made wrong script in .lua.
When you pass arguments to the locale.lookup function, it is needed that they be of the format "LOC_TEXT_TEXT". And mod's author made like this Locale.lookup("LOC_TEXT", locale.lookup("LOC_TEXT)). As you can see, second locale.lookup is wrong, it should be removed.
 
Last edited:
Back
Top Bottom