I'm working on a game project and want it to be translatable to most, if not all languages, similar to minecraft.
I've got a "Something.xml" with some japanese letters in an attribute:
Currently I am using this code to get a line from the file to an sf::String using TiCPP:
sf::String GetText(const char *_category, const char *_line) {
ticpp::Element *category = langFile.FirstChildElement(_category);
std::string lineStr;
category->GetAttribute(_line, &lineStr);
return sf::String::fromUtf8(lineStr.begin(), lineStr.end());
}
The result is that the ÕÄÖÜ get shown, but the japanese characters don't:
What should the code be?