Code: Select all
// initialize font system
FontManager &fm = FontManager::instance();
// load fonts from data directory
fm.loadAll(PlatformFactory::getMedia()->getMediaDirectory() + "\fonts");
// try to get a font - only returns -1 if there are no fonts at all
if (fm.getFaceID(BZDB.get("consoleFont")) <0>getMediaDirectory() + "\fonts");
printFatalError("Path: " + PlatformFactory::getMedia()->getMediaDirectory()); //This line is new
// try to get a font - only returns -1 if there are no fonts at all
if (fm.getFaceID(BZDB.get("consoleFont")) <0> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>,
1> _Ax=std::allocator<char>
1> ]
1> No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
getMediaDirectory() should return a string, but it seems to me that it returns a std::basic_string<_Elem>. Then i tried it with:
Code: Select all
cout << "Pfad: " <<PlatformFactory>getMediaDirectory().c_str() << endl;
The preview cuts some of my text i entered out, i try to post it. if it don't work i'll post again