From 7affd71443b3048b2390ba608ae675def3e73baf Mon Sep 17 00:00:00 2001 From: Frank Zago Date: Mon, 25 Jan 2010 03:09:42 +0000 Subject: [PATCH] (linux) Saved games are not in the data directory. --- client/CPlayerInterface.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/client/CPlayerInterface.cpp b/client/CPlayerInterface.cpp index e15631ddf..cb0b40123 100644 --- a/client/CPlayerInterface.cpp +++ b/client/CPlayerInterface.cpp @@ -33,7 +33,7 @@ #include #include #include -#include +#include #include #include #include @@ -738,7 +738,7 @@ void CPlayerInterface::showInfoDialog(const std::string &text, const std::vector { waitWhileDialog(); boost::unique_lock un(*pim); - + if(stillMoveHero.get() == DURING_MOVE)//if we are in the middle of hero movement stillMoveHero.setn(STOP_MOVE); //after showing dialog movement will be stopped @@ -795,7 +795,7 @@ void CPlayerInterface::showBlockingDialog( const std::string &text, const std::v int charperline = 35; if (pom.size() > 1) - charperline = 50; + charperline = 50; CSelWindow * temp = new CSelWindow(text, playerID, charperline, intComps, pom, askID); GH.pushInt(temp); intComps[0]->clickLeft(true, false); @@ -903,7 +903,7 @@ void CPlayerInterface::redrawHeroWin(const CGHeroInstance * hero) return; } SDL_FreeSurface(graphics->heroWins[hero->subID]); - graphics->heroWins[hero->subID] = infoWin(hero); + graphics->heroWins[hero->subID] = infoWin(hero); if (adventureInt->selection == hero) adventureInt->infoBar.draw(screen); } @@ -1067,8 +1067,8 @@ void CPlayerInterface::newObject( const CGObjectInstance * obj ) boost::unique_lock un(*pim); CGI->mh->printObject(obj); //we might have built a boat in shipyard in opened town screen - if(obj->ID == 8 - && LOCPLINT->castleInt + if(obj->ID == 8 + && LOCPLINT->castleInt && obj->pos-obj->getVisitableOffset() == LOCPLINT->castleInt->town->bestLocation()) { CGI->soundh->playSound(soundBase::newBuilding); @@ -1143,7 +1143,7 @@ int CPlayerInterface::getLastIndex( std::string namePrefix) std::map dates; //save number => datestamp directory_iterator enddir; - for (directory_iterator dir(DATA_DIR "/Games"); dir!=enddir; dir++) + for (directory_iterator dir(GVCMIDirs.UserPath + "/Games"); dir!=enddir; dir++) { if(is_regular(dir->status())) {