Rename CSoundInterface::AddMusicFiles to CacheCommonMusic

dev-time-step
krzys-h 2016-01-24 21:31:45 +01:00
parent 5f01153c5f
commit 76c43cddb2
5 changed files with 9 additions and 7 deletions

View File

@ -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");

View File

@ -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]);

View File

@ -193,5 +193,5 @@ std::string CSystemUtils::GetLangPath()
std::string CSystemUtils::GetSaveDir()
{
return std::string("save");
return std::string("saves");
}

View File

@ -54,7 +54,7 @@ void CSoundInterface::CacheAll()
}
}
void CSoundInterface::AddMusicFiles()
void CSoundInterface::CacheCommonMusic()
{
CacheMusic("music/Intro1.ogg");
CacheMusic("music/Intro2.ogg");

View File

@ -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.