mirror of
https://github.com/ENSL/NS.git
synced 2025-02-18 01:52:30 +00:00
add check for cl_musicenabled before initing fmod
This commit is contained in:
parent
a4970388ef
commit
5cf36cb28f
2 changed files with 3 additions and 3 deletions
|
@ -6524,7 +6524,7 @@ void AvHHud::UpdateAmbientSounds()
|
||||||
|
|
||||||
for(AmbientSoundListType::iterator theIter = this->mAmbientSounds.begin(); theIter != this->mAmbientSounds.end(); theIter++)
|
for(AmbientSoundListType::iterator theIter = this->mAmbientSounds.begin(); theIter != this->mAmbientSounds.end(); theIter++)
|
||||||
{
|
{
|
||||||
if (CVAR_GET_FLOAT("cl_ambientsound") != 0)
|
if (CVAR_GET_FLOAT("cl_ambientsound") != 0 || CVAR_GET_FLOAT("cl_musicenabled") != 0)
|
||||||
theIter->StartPlayingIfNot();
|
theIter->StartPlayingIfNot();
|
||||||
|
|
||||||
theIter->UpdateVolume(theListenerPosition);
|
theIter->UpdateVolume(theListenerPosition);
|
||||||
|
|
|
@ -530,7 +530,7 @@ int UIHud::Redraw(float flTime, int intermission)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Initialize music the first time through
|
// Initialize music the first time through
|
||||||
if (CVAR_GET_FLOAT("cl_ambientsound") != 0)
|
if (CVAR_GET_FLOAT("cl_ambientsound") != 0 || CVAR_GET_FLOAT("cl_musicenabled") != 0)
|
||||||
this->InitializeSound();
|
this->InitializeSound();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -628,7 +628,7 @@ bool UIHud::Update(float inCurrentTime, string& outError)
|
||||||
this->mManager.Update(inCurrentTime);
|
this->mManager.Update(inCurrentTime);
|
||||||
|
|
||||||
bool theSuccess = true;
|
bool theSuccess = true;
|
||||||
if (CVAR_GET_FLOAT("cl_ambientsound") != 0) {
|
if (CVAR_GET_FLOAT("cl_ambientsound") != 0 || CVAR_GET_FLOAT("cl_musicenabled") != 0) {
|
||||||
this->UpdateMusic(inCurrentTime);
|
this->UpdateMusic(inCurrentTime);
|
||||||
|
|
||||||
//bool theSuccess = this->UpdateInternetStream(inCurrentTime, outError);
|
//bool theSuccess = this->UpdateInternetStream(inCurrentTime, outError);
|
||||||
|
|
Loading…
Reference in a new issue