Cyrillic characters shows not correct in the bundle (1.2.163) (SOLVED)

#1

Interesting bug found in the latest version of Defold (no in previous).
I have one screen in the game where changable strings contains in the gui_script. And all correct in win dm_engine, but not correct in bundle, HTML5 for example on screenshot (the same in Android bunlde):

Looks like an encoding issue.

BUT all is correct with strings that contains in JSON file, then converting into the table in runtime and then seting into the gui label:

3 Likes

Defold 1.2.163 has been released
Missing Font (SOLVED)
#2

Thanks. We’re looking into this today. Ping @mats.gisselson

2 Likes

#4

UPD:
works correct if make bundle on Mac:

2 Likes

#5

Yes, we’re able to reproduce it and Mathias is investigating it.

0 Likes

#6

Also, small thing noticed.
The same an editor version (sha1) on Mac and Windows PC, but a bit different a bundle size:
2019-10-10_21-42-13

2 Likes

#7

We’ve finally pinpointed the culprit, and it was that some code in bob.jar started relying on UTF-8 encoding. And this has worked depending on your local system settings.
This affected any system where this was controlled by the system, for java. (e.g. older osx’s, windows)

As a current workaround, you can set this variable in three ways:

Editor 2

Open the ./Defold/config file and add the property at the front of the vmargs setting:

vmargs = -Dfile.encoding=UTF-8,....<leave the rest as-is>...

Bob.jar

Add the property when invoking java:

$ java -Dfile.encoding=UTF-8 -jar bob.jar …

Environment variable

Set an environment variable (don’t forget to remove it later!):

JAVA_TOOL_OPTIONS=-Dfile.encoding=UTF-8
3 Likes

#8

I’ve tested the first variant: works fine, thanks!

1 Like

#9

There’s now a new editor released with this fix (87eb61bb3cb7fba6333c60a085570154c380d08e).

A bob.jar fix will arrive next Defold release.

2 Likes

Missing Font (SOLVED)