cleanup
This commit is contained in:
@@ -8,11 +8,10 @@
|
|||||||
static ThemeMetric<float> THEME_SCREEN_WIDTH("Common","ScreenWidth");
|
static ThemeMetric<float> THEME_SCREEN_WIDTH("Common","ScreenWidth");
|
||||||
static ThemeMetric<float> THEME_SCREEN_HEIGHT("Common","ScreenHeight");
|
static ThemeMetric<float> THEME_SCREEN_HEIGHT("Common","ScreenHeight");
|
||||||
|
|
||||||
//
|
/* The theme's logical resolution specifies the minimum screen width and
|
||||||
// The theme's logical resolution specifies the minimum screen width
|
* the minimum screen height with a 4:3 aspect ratio. Scale just one
|
||||||
// and the minimum screen height with a 4:3 aspect ratio. Scale just one
|
* of the dimensions up to meet the requested aspect ratio.
|
||||||
// of the dimensions up to meet the requested aspect ratio.
|
*/
|
||||||
//
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The theme resolution isn't necessarily 4:3; a natively widescreen
|
* The theme resolution isn't necessarily 4:3; a natively widescreen
|
||||||
|
|||||||
@@ -385,32 +385,6 @@ void ScreenSelectMusic::Input( const InputEventPlus &input )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// saturn2888 likes to make me pollute my source code with shit that only
|
|
||||||
// he will use
|
|
||||||
#if defined(SAT2888)
|
|
||||||
if( INPUTFILTER->IsBeingPressed(DeviceInput(DEVICE_KEYBOARD, KEY_LSHIFT))
|
|
||||||
|| INPUTFILTER->IsBeingPressed(DeviceInput(DEVICE_KEYBOARD, KEY_RSHIFT)) )
|
|
||||||
{
|
|
||||||
switch( input.DeviceI.button )
|
|
||||||
{
|
|
||||||
case KEY_SPACE:
|
|
||||||
// clear all mods for all players
|
|
||||||
FOREACH_HumanPlayer( pn )
|
|
||||||
{
|
|
||||||
/*
|
|
||||||
GAMESTATE->m_pPlayerState[pn]->m_PlayerOptions.Init();
|
|
||||||
GAMESTATE->m_pPlayerState[pn]->m_PlayerOptions.FromString( PREFSMAN->m_sDefaultModifiers );
|
|
||||||
*/
|
|
||||||
GAMESTATE->m_pPlayerState[pn]->ResetToDefaultPlayerOptions( ModsLevel_Preferred );
|
|
||||||
}
|
|
||||||
m_soundOptionsChange.Play();
|
|
||||||
MESSAGEMAN->Broadcast("PlayerOptionsChanged");
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
// and for that saturn2888 is a nignog
|
|
||||||
|
|
||||||
// debugging?
|
// debugging?
|
||||||
// I just like being able to see untransliterated titles occasionally.
|
// I just like being able to see untransliterated titles occasionally.
|
||||||
if( input.DeviceI.device == DEVICE_KEYBOARD && input.DeviceI.button == KEY_F9 )
|
if( input.DeviceI.device == DEVICE_KEYBOARD && input.DeviceI.button == KEY_F9 )
|
||||||
|
|||||||
+11
-21
@@ -105,13 +105,12 @@ void StepMania::GetPreferredVideoModeParams( VideoModeParams ¶msOut )
|
|||||||
* -Chris
|
* -Chris
|
||||||
*/
|
*/
|
||||||
int iWidth = PREFSMAN->m_iDisplayWidth;
|
int iWidth = PREFSMAN->m_iDisplayWidth;
|
||||||
// SAT2888 but could also be useful disabled
|
|
||||||
/*
|
|
||||||
if( PREFSMAN->m_bWindowed )
|
if( PREFSMAN->m_bWindowed )
|
||||||
{
|
{
|
||||||
iWidth = PREFSMAN->m_iDisplayHeight * PREFSMAN->m_fDisplayAspectRatio;
|
float fRatio = PREFSMAN->m_iDisplayWidth / PREFSMAN->m_iDisplayHeight;
|
||||||
|
//iWidth = PREFSMAN->m_iDisplayHeight * PREFSMAN->m_fDisplayAspectRatio;
|
||||||
|
iWidth = PREFSMAN->m_iDisplayHeight * fRatio;
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
|
|
||||||
paramsOut = VideoModeParams(
|
paramsOut = VideoModeParams(
|
||||||
PREFSMAN->m_bWindowed,
|
PREFSMAN->m_bWindowed,
|
||||||
@@ -295,11 +294,6 @@ void StepMania::ResetPreferences()
|
|||||||
* these may still be NULL. */
|
* these may still be NULL. */
|
||||||
void ShutdownGame()
|
void ShutdownGame()
|
||||||
{
|
{
|
||||||
#if defined(SAT2888)
|
|
||||||
LOG->Info("sm-ssc is Copyright ©2009,2010 the spinal shark collective, all rights reserved. Commercial use of this binary is prohibited by law and will be prosecuted to the fullest extent of the law.");
|
|
||||||
if(rand()%64 == 24)
|
|
||||||
LOG->Info("NAKET Coder isn't a fan of four panel footprint either, and would love to shit over your theme like you say NAKET Team shit over the options screen.");
|
|
||||||
#endif
|
|
||||||
/* First, tell SOUNDMAN that we're shutting down. This signals sound drivers to
|
/* First, tell SOUNDMAN that we're shutting down. This signals sound drivers to
|
||||||
* stop sounds, which we want to do before any threads that may have started sounds
|
* stop sounds, which we want to do before any threads that may have started sounds
|
||||||
* are closed; this prevents annoying DirectSound glitches and delays. */
|
* are closed; this prevents annoying DirectSound glitches and delays. */
|
||||||
@@ -402,7 +396,7 @@ static void AdjustForChangedSystemCapabilities()
|
|||||||
LOG->Trace( "Memory changed from %i to %i; settings changed", g_iLastSeenMemory.Get(), Memory );
|
LOG->Trace( "Memory changed from %i to %i; settings changed", g_iLastSeenMemory.Get(), Memory );
|
||||||
g_iLastSeenMemory.Set( Memory );
|
g_iLastSeenMemory.Set( Memory );
|
||||||
|
|
||||||
// is this assumption outdated?
|
// is this assumption outdated? -aj
|
||||||
/* Let's consider 128-meg systems low-memory, and 256-meg systems high-memory.
|
/* Let's consider 128-meg systems low-memory, and 256-meg systems high-memory.
|
||||||
* Cut off at 192. This is somewhat conservative; many 128-meg systems can
|
* Cut off at 192. This is somewhat conservative; many 128-meg systems can
|
||||||
* deal with higher memory profile settings, but some can't.
|
* deal with higher memory profile settings, but some can't.
|
||||||
@@ -869,7 +863,7 @@ void StepMania::ChangeCurrentGame( const Game* g )
|
|||||||
ANNOUNCER->SwitchAnnouncer( sAnnouncer );
|
ANNOUNCER->SwitchAnnouncer( sAnnouncer );
|
||||||
THEME->SwitchThemeAndLanguage( sTheme, sLanguage, PREFSMAN->m_bPseudoLocalize );
|
THEME->SwitchThemeAndLanguage( sTheme, sLanguage, PREFSMAN->m_bPseudoLocalize );
|
||||||
|
|
||||||
/* Set the input scheme for the new game, and load keymaps. */
|
// Set the input scheme for the new game, and load keymaps.
|
||||||
if( INPUTMAPPER )
|
if( INPUTMAPPER )
|
||||||
{
|
{
|
||||||
INPUTMAPPER->SetInputScheme( &g->m_InputScheme );
|
INPUTMAPPER->SetInputScheme( &g->m_InputScheme );
|
||||||
@@ -992,13 +986,13 @@ int main(int argc, char* argv[])
|
|||||||
runmode = RunMode_DisplayVersion;
|
runmode = RunMode_DisplayVersion;
|
||||||
|
|
||||||
|
|
||||||
/* Set up arch hooks first. This may set up crash handling. */
|
// Set up arch hooks first. This may set up crash handling.
|
||||||
HOOKS = ArchHooks::Create();
|
HOOKS = ArchHooks::Create();
|
||||||
HOOKS->Init();
|
HOOKS->Init();
|
||||||
|
|
||||||
LUA = new LuaManager;
|
LUA = new LuaManager;
|
||||||
|
|
||||||
/* Almost everything uses this to read and write files. Load this early. */
|
// Almost everything uses this to read and write files. Load this early.
|
||||||
FILEMAN = new RageFileManager( argv[0] );
|
FILEMAN = new RageFileManager( argv[0] );
|
||||||
FILEMAN->MountInitialFilesystems();
|
FILEMAN->MountInitialFilesystems();
|
||||||
bool bPortable = DoesFileExist("Portable.ini");
|
bool bPortable = DoesFileExist("Portable.ini");
|
||||||
@@ -1009,11 +1003,9 @@ int main(int argc, char* argv[])
|
|||||||
/* Set this up next. Do this early, since it's needed for RageException::Throw. */
|
/* Set this up next. Do this early, since it's needed for RageException::Throw. */
|
||||||
LOG = new RageLog;
|
LOG = new RageLog;
|
||||||
|
|
||||||
/* Whew--we should be able to crash safely now! */
|
// Whew--we should be able to crash safely now!
|
||||||
|
|
||||||
//
|
|
||||||
// load preferences and mount any alternative trees.
|
// load preferences and mount any alternative trees.
|
||||||
//
|
|
||||||
PREFSMAN = new PrefsManager;
|
PREFSMAN = new PrefsManager;
|
||||||
|
|
||||||
/* Allow HOOKS to check for multiple instances. We need to do this after PREFS is initialized,
|
/* Allow HOOKS to check for multiple instances. We need to do this after PREFS is initialized,
|
||||||
@@ -1034,7 +1026,7 @@ int main(int argc, char* argv[])
|
|||||||
|
|
||||||
WriteLogHeader();
|
WriteLogHeader();
|
||||||
|
|
||||||
/* Set up alternative filesystem trees. */
|
// Set up alternative filesystem trees.
|
||||||
if( PREFSMAN->m_sAdditionalFolders.Get() != "" )
|
if( PREFSMAN->m_sAdditionalFolders.Get() != "" )
|
||||||
{
|
{
|
||||||
vector<RString> dirs;
|
vector<RString> dirs;
|
||||||
@@ -1065,16 +1057,14 @@ int main(int argc, char* argv[])
|
|||||||
PREFSMAN->ReadPrefsFromDisk();
|
PREFSMAN->ReadPrefsFromDisk();
|
||||||
ApplyLogPreferences();
|
ApplyLogPreferences();
|
||||||
|
|
||||||
/* This needs PREFSMAN. */
|
// This needs PREFSMAN.
|
||||||
Dialog::Init();
|
Dialog::Init();
|
||||||
|
|
||||||
//
|
|
||||||
// Create game objects
|
// Create game objects
|
||||||
//
|
|
||||||
|
|
||||||
GAMESTATE = new GameState;
|
GAMESTATE = new GameState;
|
||||||
|
|
||||||
/* This requires PREFSMAN, for PREFSMAN->m_bShowLoadingWindow. */
|
// This requires PREFSMAN, for PREFSMAN->m_bShowLoadingWindow.
|
||||||
LoadingWindow *pLoadingWindow = NULL;
|
LoadingWindow *pLoadingWindow = NULL;
|
||||||
switch( runmode )
|
switch( runmode )
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user