[colobot] 236/377: Rename CSoundInterface::AddMusicFiles to CacheCommonMusic

Didier Raboud odyx at moszumanska.debian.org
Wed Mar 30 13:34:21 UTC 2016


This is an automated email from the git hooks/post-receive script.

odyx pushed a commit to branch debian/master
in repository colobot.

commit 76c43cddb2464673f0d2041ec6de90b87be02bdf
Author: krzys-h <krzys_h at interia.pl>
Date:   Sun Jan 24 21:31:45 2016 +0100

    Rename CSoundInterface::AddMusicFiles to CacheCommonMusic
---
 src/app/app.cpp     | 2 +-
 src/app/main.cpp    | 8 +++++---
 src/app/system.cpp  | 2 +-
 src/sound/sound.cpp | 2 +-
 src/sound/sound.h   | 2 +-
 5 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/src/app/app.cpp b/src/app/app.cpp
index 10baa73..a12057b 100644
--- a/src/app/app.cpp
+++ b/src/app/app.cpp
@@ -457,7 +457,7 @@ bool CApplication::Create()
 
     m_sound->Create();
     m_sound->CacheAll();
-    m_sound->AddMusicFiles();
+    m_sound->CacheCommonMusic();
 
     GetLogger()->Info("CApplication created successfully\n");
 
diff --git a/src/app/main.cpp b/src/app/main.cpp
index 7d3e665..ecfd253 100644
--- a/src/app/main.cpp
+++ b/src/app/main.cpp
@@ -93,6 +93,11 @@ int main(int argc, char *argv[])
 {
     CLogger logger; // single instance of logger
 
+    auto systemUtils = CSystemUtils::Create(); // platform-specific utils
+    systemUtils->Init();
+
+    logger.SetOutputFile(systemUtils->GetSaveDir() + "/log.txt");
+
     // Workaround for character encoding in argv on Windows
     #if PLATFORM_WINDOWS
     int wargc = 0;
@@ -124,9 +129,6 @@ int main(int argc, char *argv[])
 
     logger.Info("%s starting\n", COLOBOT_FULLNAME);
 
-    auto systemUtils = CSystemUtils::Create(); // platform-specific utils
-    systemUtils->Init();
-
     CSignalHandlers::Init(systemUtils.get());
 
     CResourceManager manager(argv[0]);
diff --git a/src/app/system.cpp b/src/app/system.cpp
index 01450c4..2b0e159 100644
--- a/src/app/system.cpp
+++ b/src/app/system.cpp
@@ -193,5 +193,5 @@ std::string CSystemUtils::GetLangPath()
 
 std::string CSystemUtils::GetSaveDir()
 {
-    return std::string("save");
+    return std::string("saves");
 }
diff --git a/src/sound/sound.cpp b/src/sound/sound.cpp
index fb10d2f..307f93d 100644
--- a/src/sound/sound.cpp
+++ b/src/sound/sound.cpp
@@ -54,7 +54,7 @@ void CSoundInterface::CacheAll()
     }
 }
 
-void CSoundInterface::AddMusicFiles()
+void CSoundInterface::CacheCommonMusic()
 {
     CacheMusic("music/Intro1.ogg");
     CacheMusic("music/Intro2.ogg");
diff --git a/src/sound/sound.h b/src/sound/sound.h
index cb37e08..29ce576 100644
--- a/src/sound/sound.h
+++ b/src/sound/sound.h
@@ -73,7 +73,7 @@ public:
     void CacheAll();
 
     /** Function called to add all music files to list */
-    void AddMusicFiles();
+    void CacheCommonMusic();
 
     /** Function called to cache sound effect file.
      *  This function is called by plugin interface for each file.

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/colobot.git



More information about the Pkg-games-commits mailing list