Do not set / enable / show the s_openal CVAR if the binary is build

without OpenAL support. OpenAL is enabled in the default Makefile and if
it's disabled, it's shown at startup.
This commit is contained in:
Yamagi Burmeister 2012-04-27 12:00:22 +00:00
parent 363dc5d311
commit 1a0b4ebad5

View file

@ -150,12 +150,7 @@ S_Init ( void )
Cmd_AddCommand( "ogg_shutdown", OGG_Shutdown );
#endif
#if ! USE_OPENAL
cv = Cvar_Get( "s_openal", "0", CVAR_ARCHIVE);
if( cv->value ) {
Com_Printf("Warning: Ignoring s_openal, as this binary has no OpenAL support!");
}
#else
#if USE_OPENAL
cv = Cvar_Get( "s_openal", "1", CVAR_ARCHIVE);
if( cv->value && AL_Init() ) {
sound_started = SS_OAL;