mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
Added new, optional JA2.INI parameter to select windowed mode instead of Fullscreen ([Ja2 Setting] SCREEN_MODE_WINDOWED=1). To keep Fullscreen, simply omit this swith or set it to 0. Also, added a cmdline switch for the same effect, but with higher prio. /FULLSCREEN overwrites INI/SCREEN_MODE_WINDOWED=1 while /WINDOW overrides INI/SCREEN_MODE_WINDOWED=0.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@734 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
+13
-17
@@ -15,6 +15,7 @@
|
||||
#include "fade screen.h"
|
||||
#endif
|
||||
|
||||
extern int iScreenMode;
|
||||
|
||||
UINT32 uiMusicHandle=NO_SAMPLE;
|
||||
UINT32 uiMusicVolume=50;
|
||||
@@ -99,9 +100,10 @@ void MusicStopCallback( void *pData );
|
||||
//********************************************************************************
|
||||
BOOLEAN MusicPlay(UINT32 uiNum)
|
||||
{
|
||||
#ifndef WINDOWED_MODE
|
||||
if( 1==iScreenMode ) /* on Windowed mode, skip the music? was coded for WINDOWED_MODE that way...*/
|
||||
return FALSE;
|
||||
|
||||
SOUNDPARMS spParms;
|
||||
SOUNDPARMS spParms;
|
||||
|
||||
if(fMusicPlaying)
|
||||
MusicStop();
|
||||
@@ -128,10 +130,6 @@ SOUNDPARMS spParms;
|
||||
}
|
||||
|
||||
//DebugMsg( TOPIC_JA2, DBG_LEVEL_3, String( "Music PLay %d %d", uiMusicHandle, gubMusicMode ) );
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
return(FALSE);
|
||||
}
|
||||
|
||||
@@ -147,9 +145,11 @@ BOOLEAN MusicSetVolume(UINT32 uiVolume)
|
||||
{
|
||||
INT32 uiOldMusicVolume = uiMusicVolume;
|
||||
|
||||
#ifndef WINDOWED_MODE
|
||||
if( 1==iScreenMode ) /* on Windowed mode, skip the music? was coded for WINDOWED_MODE that way...*/
|
||||
return FALSE;
|
||||
|
||||
uiMusicVolume=__min(uiVolume, 127);
|
||||
|
||||
uiMusicVolume=__min(uiVolume, 127);
|
||||
|
||||
if(uiMusicHandle!=NO_SAMPLE)
|
||||
{
|
||||
@@ -173,8 +173,6 @@ BOOLEAN MusicSetVolume(UINT32 uiVolume)
|
||||
StartMusicBasedOnMode( );
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
return(FALSE);
|
||||
}
|
||||
|
||||
@@ -201,8 +199,8 @@ UINT32 MusicGetVolume(void)
|
||||
//********************************************************************************
|
||||
BOOLEAN MusicStop(void)
|
||||
{
|
||||
|
||||
#ifndef WINDOWED_MODE
|
||||
if( 1==iScreenMode ) /* on Windowed mode, skip the music? was coded for WINDOWED_MODE that way...*/
|
||||
return(FALSE);
|
||||
|
||||
|
||||
if(uiMusicHandle!=NO_SAMPLE)
|
||||
@@ -216,9 +214,6 @@ BOOLEAN MusicStop(void)
|
||||
}
|
||||
|
||||
//DebugMsg( TOPIC_JA2, DBG_LEVEL_3, String( "Music Stop %d %d", uiMusicHandle, gubMusicMode ) );
|
||||
|
||||
#endif
|
||||
|
||||
return(FALSE);
|
||||
}
|
||||
|
||||
@@ -271,7 +266,9 @@ BOOLEAN MusicPoll( BOOLEAN fForce )
|
||||
{
|
||||
//DebugMsg (TOPIC_JA2,DBG_LEVEL_3,"MusicPoll");
|
||||
|
||||
#ifndef WINDOWED_MODE
|
||||
if( 1==iScreenMode ) /* on Windowed mode, skip the music? was coded for WINDOWED_MODE that way...*/
|
||||
return(TRUE);
|
||||
|
||||
INT32 iVol;
|
||||
|
||||
//DebugMsg (TOPIC_JA2,DBG_LEVEL_3,"MusicPoll: SoundServiceStreams ");
|
||||
@@ -356,7 +353,6 @@ BOOLEAN MusicPoll( BOOLEAN fForce )
|
||||
gfDontRestartSong = FALSE;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
//DebugMsg (TOPIC_JA2,DBG_LEVEL_3,"MusicPoll done");
|
||||
return(TRUE);
|
||||
|
||||
Reference in New Issue
Block a user