ghorsington / CM3D2.YATranslator

Yet Another Translator -- Translation plug-in for CM3D2 remade from scratch
https://coder.horse/CM3D2.YATranslator
The Unlicense
28 stars 5 forks source link

Template strings with tags [HF] and [SF] are not retranslated #14

Closed ghorsington closed 6 years ago

ghorsington commented 6 years ago

If EnableStringReload is enabled, YAT still will not retranslate strings if they contain special tags like [HF] and [SF].

The issue is not present in UTP/TP because of how it handled these kind of strings: the plug-in replaced declared input strings as RegEx's and matched final strings (with tags replaced) against them. While this worked, it was slow, as there is no way to find a matching replacement string but to go through every single available RegEx. YAT vastly improves the speed of translation by replacing the tagged strings themselves, but as a consequence string reloading is "broken".

Currently implementing the fix is too big an issue: when strings are reloaded, YAT will receive strings with special tags replaced by names instead of the original "template". This makes finding the original untranslated string impossible without either brute-forcing all cached translations or rebuild a cache to use a data storage format more suited for this niche application.

Moreover, the issue mainly affects those who use YAT to translate the game. Even so, most of these template strings are present in the game's story portion, which does not require active string reloading.

TL;DR: The problem will remain unfixed until there is a real need to do so. As of right now, the amount of work to fix the issue outweighs the benefits of the fix.