The International Simutrans Forum

 

Author Topic: Repeating Strings vs. Individual Strings in game code [Discussion]  (Read 249 times)

0 Members and 1 Guest are viewing this topic.

Online Leartin

  • Oh no, not him again!
  • Devotee
  • *
  • Posts: 1534
  • PAK-DEV P192C
  • Languages: DE, EN
This is a discussion started in some Patch threads. The basic question: Should the game reuse strings or not?

Individual Strings have the advantage of being more flexible. Translators could translate knowing exactly where the string is going to be used, specific for that situation. The downside is more strings to translate, with a lack of translators to do so.

Repeating Strings have the advantage of having less strings in general, and new features can be implemented fully translated to each language, so long as the strings used already exist. However, the system is more rigid and does not allow for any diversion from the given base string, as that might not fit elsewhere the string is used (or will be used in the future)

I'd like this issue to be discussed here, since it's kind of important to know for anyone who wants to write patches or wants to translate. Any patchwriter should know whether they should 'try and reuse old strings' or 'try and make unique strings that won't accidentially overlap'. Any translator should know whether he can use words or a phrase that fit perfectly for the situation he sees the string used, or should rather try to use more general translations just in case the string gets reused.
Besides, if translations should strictly follow the base string, what about base strings that turned wrong by changes to how the game works?

I'm not sure a concensus can be reached, but it's certainly better to talk about it rather than programmers and translators being mad at each other for making the others job harder.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 10447
  • Languages: De,EN,JP
Re: Repeating Strings vs. Individual Strings in game code [Discussion]
« Reply #1 on: January 10, 2021, 03:08:28 PM »
To add to this:
In the past strings were recycled whenever possible, since a new string is not translated for years in most languages, despite Simutranslator. The languages that are pretty complete are English, German, Japanese, and Czech. The rest depends often on the activity of a single member in the community.

Online Leartin

  • Oh no, not him again!
  • Devotee
  • *
  • Posts: 1534
  • PAK-DEV P192C
  • Languages: DE, EN
Re: Repeating Strings vs. Individual Strings in game code [Discussion]
« Reply #2 on: January 10, 2021, 03:46:03 PM »
I absolutely get this idea. What I don't understand is why it has to be "Let's reuse StringX" rather than "Let's use a new StringY and make it a copy of StringX". The game would be just as translated that way - technically even more translated if a translation for StringX existed, since you add a new translated string ;)

Meanwhile, I'm certain there are a bunch of strings, especially single words, that should be reused - simply because even if they could be translated in several ways, they simply shouldn't as long as they refer to the same game object. To use a German example: It really doesn't matter if it's called "Fahrgast" or "Passagier", but it should always be the same word, else it becomes confusing.

---snipped some more examples for mistranslated multi-purpose strings---

Offline Andarix

  • *
  • Posts: 222
  • Languages: de
Re: Repeating Strings vs. Individual Strings in game code [Discussion]
« Reply #3 on: January 10, 2021, 04:48:08 PM »
.... The languages that are pretty complete are English, German, Japanese, and Czech. The rest depends often on the activity of a single member in the community.

https://simutrans-germany.com/wiki/wiki/en_translate_base_texts


Offline Vladki

  • Devotee
  • *
  • Posts: 3643
    • My addons, mostly roadsigns, pak128.cs
  • Languages: EN, CS
Re: Repeating Strings vs. Individual Strings in game code [Discussion]
« Reply #4 on: January 10, 2021, 05:10:42 PM »
I think that some consideration has to be done. If there are 10 dialogs that offer sorting of some list, then the label "sort by:" followed by combo box should be the same translation string.
But there may be situations where English can use the same literal string for verb, noun and adjective, while other languages have slightly different forms, or depending on context use totally different phrase.
Example: "retire".  It may be a string on the button, where it is a verb - command to retire a convoy (sell/send to depot when empty), or it may be a part of vehicle information in "retire date", which means end of production. While in English the word "retire" would be acceptable in both situations, it won't work in Czech.

Is it possible to pre-fill the translations of new strings by translation of already existing similar string? That would be helpful to avoid unnecessary extra work.

Anyway there is lot of duplicate work needed - pakset translations. The have a lot of shared strings which need to be translated over and over: e.g. factories and goods. Is there anything in simutranslator that would help - like search the same string over all paksets and mark the translation to be used in all others?

Offline Andarix

  • *
  • Posts: 222
  • Languages: de
Re: Repeating Strings vs. Individual Strings in game code [Discussion]
« Reply #5 on: January 10, 2021, 05:15:36 PM »
....
Anyway there is lot of duplicate work needed - pakset translations. The have a lot of shared strings which need to be translated over and over: e.g. factories and goods. Is there anything in simutranslator that would help - like search the same string over all paksets and mark the translation to be used in all others?

since 20 April 2014

https://forum.simutrans.com/index.php/topic,687.msg134478.html#msg134478

But that's useless if Pakset developers are of the opinion that everything should be named differently. As pak128.german and pak192.comic do.