CQUI-Org / cqui

Civilization 6 - Chao's Quick UI. Reduce clicks and manage your empire faster!
MIT License
318 stars 64 forks source link

Issue #526 - Korean rendering bug #577

Closed sbeach closed 7 years ago

sbeach commented 7 years ago

The source of this problem is the string pattern to identify where the icon needs to be inserted. From my tinkering, it seems one of the Korean characters, specifically '비', within LOC_TOOLTIP_MOVEMENT_COST is interpreted as a digit (%d) by Lua. This caused the replacement to occur in the wrong place, altering the character and causing the display error.

I tested in all languages to ensure this change does not break the implementation for other languages. The results of my testing shows that all languages supported by the base game are displayed in the following format: %.*:%s%d or ": ". This consistency in the supported languages allowed for the simplification of the gsub call within the route logic.