mirror of
https://github.com/hedge-dev/UnleashedRecomp.git
synced 2026-04-01 16:11:53 +00:00
Allow music attenuation to be enabled on Linux
This commit is contained in:
parent
6b95a6d193
commit
d53e55e056
1 changed files with 7 additions and 1 deletions
|
|
@ -20,13 +20,19 @@ static be<float>* GetVolume(bool isMusic = true)
|
|||
|
||||
bool AudioPatches::CanAttenuate()
|
||||
{
|
||||
#if _WIN32
|
||||
#if defined(_WIN32) || defined(__linux__)
|
||||
if (m_isAttenuationSupported >= 0)
|
||||
return m_isAttenuationSupported;
|
||||
|
||||
auto version = os::version::GetOSVersion();
|
||||
|
||||
#if defined(_WIN32)
|
||||
m_isAttenuationSupported = version.Major >= 10 && version.Build >= 17763;
|
||||
#endif
|
||||
|
||||
#if defined(__linux__)
|
||||
m_isAttenuationSupported = true;
|
||||
#endif
|
||||
|
||||
return m_isAttenuationSupported;
|
||||
#else
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue