Latest Posts

Topic: Productionsite tooltips

Joined: 2013-10-07, 15:56
Posts: 2811
One Elder of Players
Location: RenderedRect
Posted at: 2014-07-30, 11:10

I am currently doing another overhaul of the constructionsite tooltips, which should appear in your translation files soon. The format will look something like this: click for pretty screenshot

In this particular example, the string goes:

Skipped rearing cattle because the economy doesn't need the worker 'Ox'.

And is assembled as follows:

Part 1 - widelands file

Skipped ... because the economy doesn't need the worker '...'.

This is the main string, which is assembled from some snippets in the "widelands" po file. We have the following snippets:

Completed/Skipped/Did not start ...

... because the economy needs/doesn’t need the ware/worker '...'

... because a worker needs (no) experience

the building has/doesn't have the following wares: %s"

... because ... is/are missing

Part 2 - tribes' files

rearing cattle and Ox are taken from the tribes' files. We already have the 'Ox' in the file, but there will be a whole bunch of new strings of the type 'rearing cattle' - other examples for these are: 'working', 'forging a helmet', 'preparing a ration'.

Lists of wares - widelands file

In this context, lists of wares are now assembled in an improved manner as well - with "and" or "or" if it's the last two items in the list, and with ", " otherwise. So, we get lists like "Fish, Meat or Pitta Bread" or "Wheat and Water" now. You will see the separators with placeholders left and right, so the order of strings in the list can be reversed if needed (if you language does stuff like "Pitta Bread or Meat, Fish"). Sadly, the capitalization can't be changed right now, but I do have future plans face-wink.png

Closing Remarks

You might need to be creative with Completed/Skipped/Did not start .... For example, 'Did not start' was originally 'Failed' in English, but 'Failed working' or, even worse 'Failed to working' didn't work, so I had to change it.

Please let me know if you should run into any trouble with translating these strings, and I will do my best to help you. Languages can throw surprises at you, so I might need to change somethig in the code - I will just need to know what the problem is.

Finally, make sure you do some in-game testing with a current development build if you can, to make sure these strings all work properly for you.

Busy indexing nil values

Top Quote