The problem is, because my locale is Greek, fractional numbers use the ',' instead of '.' character. So 1.6 (on USA locale\) would be printed as 1,6.
This is a problem because when I try to load the file later, it expects 1.6 and find 1,6 and all things go wrong. This is my function:
Code: Select all
void CEditorLevel::OnSaveMap()
{
//write all nodes to one file for now
setlocale(LC_ALL,"C");
IXMLWriter* writer = m_EditorManager->getDevice()->getFileSystem()->createXMLWriter(m_MapName.c_str());
writer->writeXMLHeader();
WriteSceneNode(writer, m_EditorManager->getSceneMngr()->getRootSceneNode());
writer->drop();
}
Is there a way to fix this? Thank you.