remove MaxStages and LifeDifficulty; allow doing them with lua instead
This commit is contained in:
@@ -364,12 +364,22 @@ static void JudgeDifficulty( int &sel, bool ToSel, const ConfOption *pConfOption
|
||||
MoveMap( sel, PREFSMAN->m_fJudgeWindowScale, ToSel, mapping, ARRAYSIZE(mapping) );
|
||||
}
|
||||
|
||||
void LifeDifficulty( int &sel, bool ToSel, const ConfOption *pConfOption )
|
||||
static void LifeDifficulty( int &sel, bool ToSel, const ConfOption *pConfOption )
|
||||
{
|
||||
const float mapping[] = { 1.60f,1.40f,1.20f,1.00f,0.80f,0.60f,0.40f };
|
||||
MoveMap( sel, PREFSMAN->m_fLifeDifficultyScale, ToSel, mapping, ARRAYSIZE(mapping) );
|
||||
}
|
||||
|
||||
static int GetLifeDifficulty()
|
||||
{
|
||||
int iLifeDifficulty;
|
||||
LifeDifficulty( iLifeDifficulty, true, NULL );
|
||||
iLifeDifficulty++; // LifeDifficulty returns an index
|
||||
return iLifeDifficulty;
|
||||
}
|
||||
#include "LuaFunctions.h"
|
||||
LuaFunction( GetLifeDifficulty, GetLifeDifficulty() );
|
||||
|
||||
static void ShowSongOptions( int &sel, bool ToSel, const ConfOption *pConfOption )
|
||||
{
|
||||
const PrefsManager::Maybe mapping[] = { PrefsManager::NO,PrefsManager::YES,PrefsManager::ASK };
|
||||
|
||||
@@ -61,11 +61,6 @@ struct ConfOption
|
||||
void (*MakeOptionsListCB)( CStringArray &out );
|
||||
};
|
||||
|
||||
|
||||
// HACK: This is used by ScreenTitleMenu
|
||||
void LifeDifficulty( int &sel, bool ToSel, const ConfOption *pConfOption );
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
|
||||
@@ -19,7 +19,6 @@
|
||||
#include "LightsManager.h"
|
||||
#include "CommonMetrics.h"
|
||||
#include "Game.h"
|
||||
#include "ScreenOptionsMasterPrefs.h"
|
||||
|
||||
#define MAX_STAGES_TEXT THEME->GetMetric (m_sName,"MaxStagesText")
|
||||
#define COIN_MODE_CHANGE_SCREEN THEME->GetMetric (m_sName,"CoinModeChangeScreen")
|
||||
@@ -68,25 +67,6 @@ void ScreenTitleMenu::Init()
|
||||
this->AddChild( &m_textSongs );
|
||||
SET_XY_AND_ON_COMMAND( m_textSongs );
|
||||
|
||||
m_textMaxStages.LoadFromFont( THEME->GetPathF(m_sName,"MaxStages") );
|
||||
m_textMaxStages.SetName( "MaxStages" );
|
||||
CString sText =
|
||||
GAMESTATE->IsEventMode() ?
|
||||
CString("event mode") :
|
||||
ssprintf( "%d %s%s max", PREFSMAN->m_iSongsPerPlay.Get(), MAX_STAGES_TEXT.c_str(), (PREFSMAN->m_iSongsPerPlay>1)?"s":"" );
|
||||
m_textMaxStages.SetText( sText );
|
||||
this->AddChild( &m_textMaxStages );
|
||||
SET_XY_AND_ON_COMMAND( m_textMaxStages );
|
||||
|
||||
m_textLifeDifficulty.LoadFromFont( THEME->GetPathF(m_sName,"LifeDifficulty") );
|
||||
m_textLifeDifficulty.SetName( "LifeDifficulty" );
|
||||
int iLifeDifficulty;
|
||||
LifeDifficulty( iLifeDifficulty, true, NULL );
|
||||
iLifeDifficulty++; // LifeDifficulty returns an index
|
||||
m_textLifeDifficulty.SetText( ssprintf( "life difficulty %d", iLifeDifficulty ) );
|
||||
this->AddChild( &m_textLifeDifficulty );
|
||||
SET_XY_AND_ON_COMMAND( m_textLifeDifficulty );
|
||||
|
||||
this->SortByDrawOrder();
|
||||
|
||||
SOUND->PlayOnceFromAnnouncer( "title menu game name" );
|
||||
|
||||
@@ -26,8 +26,6 @@ private:
|
||||
AutoActor m_sprLogo;
|
||||
BitmapText m_textVersion;
|
||||
BitmapText m_textSongs;
|
||||
BitmapText m_textMaxStages;
|
||||
BitmapText m_textLifeDifficulty;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user