Whenever I use these letters in e.g. GUI, they always come out like this: “??” instead… I suspect that it has something to do with the encoding of the scripts I’m using, but AFAIK MonoDevelop is already using UTF-8 as default.
So, have anyone had the same problem and maybe a solution to it?
UPDATE: I tried to save one of my scripts containing the special characters as UTF-16 in MonoDevelop and then use that script instead of the default UTF-8. Still question marks instead of ‘æ’, ‘ø’ and ‘å’…
If you “type” the unicode characters in your editor you might run into such issues, especially when using your source code on multiple platforms or in different editors.
As a first solution you can hard code the unicode character into your text, something like:
Debug.Log ("Fran\u00E7ais");
This will ensure a proper display in the console and in the GUI.
However, hard coding strings into your source code isn’t considered the best practice. If you need lots of (international) text, consider saving it in an asset file (also useful for localization), where you can ensure that it’s stored with the proper encoding.link text