diff --git a/source/glest_game/game/game.cpp b/source/glest_game/game/game.cpp index fc89b204..1e2b1ed7 100644 --- a/source/glest_game/game/game.cpp +++ b/source/glest_game/game/game.cpp @@ -919,8 +919,8 @@ void Game::init(bool initForPreviewOnly) { world.init(this, gameSettings.getDefaultUnits()); } catch(const exception &ex) { - char szBuf[4096]=""; - sprintf(szBuf,"In [%s::%s Line: %d] Error [%s]\n",extractFileFromDirectoryPath(__FILE__).c_str(),__FUNCTION__,__LINE__,ex.what()); + char szBuf[8096]=""; + sprintf(szBuf,"In [%s::%s Line: %d]\nError [%s]\n",extractFileFromDirectoryPath(__FILE__).c_str(),__FUNCTION__,__LINE__,ex.what()); SystemFlags::OutputDebug(SystemFlags::debugError,szBuf); if(SystemFlags::getSystemSettingType(SystemFlags::debugSystem).enabled) SystemFlags::OutputDebug(SystemFlags::debugSystem,szBuf); diff --git a/source/glest_game/world/world.cpp b/source/glest_game/world/world.cpp index b58e5b6a..a19d1418 100644 --- a/source/glest_game/world/world.cpp +++ b/source/glest_game/world/world.cpp @@ -262,14 +262,17 @@ void World::init(Game *game, bool createUnits, bool initFactions){ char szErrBuf[8096]=""; try { - if(createUnits){ + if(createUnits) { initUnits(); } } catch(const std::exception &ex) { + //printf("***A\n"); gotError = true; - sprintf(szErrBuf,"In [%s::%s %d] error [%s]\n",__FILE__,__FUNCTION__,__LINE__,ex.what()); + sprintf(szErrBuf,"In [%s::%s %d]\nerror [%s]\n",__FILE__,__FUNCTION__,__LINE__,ex.what()); SystemFlags::OutputDebug(SystemFlags::debugError,szErrBuf); + + //printf("***B\n"); } if(loadWorldNode != NULL) { @@ -1676,7 +1679,7 @@ void World::initUnits() { } catch(const std::exception &ex) { gotError = true; - sprintf(szErrBuf,"In [%s::%s %d] error [%s]\n",__FILE__,__FUNCTION__,__LINE__,ex.what()); + sprintf(szErrBuf,"In [%s::%s %d]\nerror [%s]\n",__FILE__,__FUNCTION__,__LINE__,ex.what()); SystemFlags::OutputDebug(SystemFlags::debugError,szErrBuf); }