tweak ScreenRaveOptions
This commit is contained in:
@@ -2878,6 +2878,15 @@ NextScreen=ScreenStage
|
|||||||
TimerSeconds=30
|
TimerSeconds=30
|
||||||
StyleIcon=0
|
StyleIcon=0
|
||||||
|
|
||||||
|
OptionMenuFlags=rows,6
|
||||||
|
|
||||||
|
Line1=list,Speed
|
||||||
|
Line2=list,Accel
|
||||||
|
Line3=list,Scroll
|
||||||
|
Line4=list,NoteSkins
|
||||||
|
Line5=list,Persp
|
||||||
|
Line6=Steps
|
||||||
|
|
||||||
[ScreenSongOptions]
|
[ScreenSongOptions]
|
||||||
PrevScreenArcade=ScreenPlayerOptions
|
PrevScreenArcade=ScreenPlayerOptions
|
||||||
PrevScreenNonstop=ScreenPlayerOptions
|
PrevScreenNonstop=ScreenPlayerOptions
|
||||||
|
|||||||
@@ -57,6 +57,8 @@ static int g_iLastSongShown = 0;
|
|||||||
#define PERCENT_START_Y THEME->GetMetricF("ScreenRanking","PercentStartY")
|
#define PERCENT_START_Y THEME->GetMetricF("ScreenRanking","PercentStartY")
|
||||||
#define PERCENT_ON_COMMAND( l ) THEME->GetMetric ("ScreenRanking",ssprintf("Percent%dOnCommand",l+1))
|
#define PERCENT_ON_COMMAND( l ) THEME->GetMetric ("ScreenRanking",ssprintf("Percent%dOnCommand",l+1))
|
||||||
#define PERCENT_OFF_COMMAND( l ) THEME->GetMetric ("ScreenRanking",ssprintf("Percent%dOffCommand",l+1))
|
#define PERCENT_OFF_COMMAND( l ) THEME->GetMetric ("ScreenRanking",ssprintf("Percent%dOffCommand",l+1))
|
||||||
|
#define PERCENT_DECIMAL_PLACES THEME->GetMetricI("ScreenRanking","PercentDecimalPlaces")
|
||||||
|
#define PERCENT_TOTAL_SIZE THEME->GetMetricI("ScreenRanking","PercentTotalSize")
|
||||||
#define DIFFICULTY_START_X THEME->GetMetricF("ScreenRanking","DifficultyStartX")
|
#define DIFFICULTY_START_X THEME->GetMetricF("ScreenRanking","DifficultyStartX")
|
||||||
#define DIFFICULTY_START_Y THEME->GetMetricF("ScreenRanking","DifficultyStartY")
|
#define DIFFICULTY_START_Y THEME->GetMetricF("ScreenRanking","DifficultyStartY")
|
||||||
#define DIFFICULTY_SPACING_X THEME->GetMetricF("ScreenRanking","DifficultySpacingX")
|
#define DIFFICULTY_SPACING_X THEME->GetMetricF("ScreenRanking","DifficultySpacingX")
|
||||||
@@ -554,8 +556,10 @@ void ScreenRanking::SetPage( PageToShow pts )
|
|||||||
if( hs.sName.empty() )
|
if( hs.sName.empty() )
|
||||||
hs.sName = EMPTY_SCORE_NAME;
|
hs.sName = EMPTY_SCORE_NAME;
|
||||||
|
|
||||||
m_textPercent[l][d].SetText( ssprintf("%s\n%0.3f%%", hs.sName.c_str(), hs.fPercentDP*100) );
|
CString s;
|
||||||
m_textPercent[l][d].SetText( ssprintf("%s\n%0.3f%%", hs.sName.c_str(), hs.fPercentDP*100) );
|
s = hs.sName + "\n";
|
||||||
|
s += ssprintf( "%0*.*f%%", PERCENT_TOTAL_SIZE, PERCENT_DECIMAL_PLACES, hs.fPercentDP*100 );
|
||||||
|
m_textPercent[l][d].SetText( s );
|
||||||
m_textPercent[l][d].SetDiffuse( TEXT_COLOR(pts.colorIndex) );
|
m_textPercent[l][d].SetDiffuse( TEXT_COLOR(pts.colorIndex) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -25,47 +25,9 @@
|
|||||||
#define PREV_SCREEN THEME->GetMetric ("ScreenRaveOptions","PrevScreen")
|
#define PREV_SCREEN THEME->GetMetric ("ScreenRaveOptions","PrevScreen")
|
||||||
#define NEXT_SCREEN THEME->GetMetric ("ScreenRaveOptions","NextScreen")
|
#define NEXT_SCREEN THEME->GetMetric ("ScreenRaveOptions","NextScreen")
|
||||||
|
|
||||||
enum {
|
ScreenRaveOptions::ScreenRaveOptions( CString sClassName ): ScreenOptionsMaster( sClassName )
|
||||||
RO_SUPER_GROWTH,
|
|
||||||
RO_CPU_SKILL,
|
|
||||||
NUM_RAVE_OPTIONS_LINES
|
|
||||||
};
|
|
||||||
|
|
||||||
OptionRow g_RaveOptionsLines[NUM_RAVE_OPTIONS_LINES] = {
|
|
||||||
OptionRow( "Super\nGrowth", false, "25%","50%","75%","100%","125%","150%","175%","200%" ),
|
|
||||||
OptionRow( "CPU\nSkill", true, "-5","-4","-3","-2","-1","DEFAULT","+1","+2","+3","+4","+5" )
|
|
||||||
};
|
|
||||||
|
|
||||||
ScreenRaveOptions::ScreenRaveOptions( CString sClassName ): ScreenOptions( sClassName )
|
|
||||||
{
|
{
|
||||||
LOG->Trace( "ScreenRaveOptions::ScreenRaveOptions()" );
|
LOG->Trace( "ScreenRaveOptions::ScreenRaveOptions()" );
|
||||||
|
|
||||||
Init(
|
|
||||||
INPUTMODE_TOGETHER,
|
|
||||||
g_RaveOptionsLines,
|
|
||||||
GAMESTATE->AnyPlayersAreCpu()? 2 : 1 );
|
|
||||||
}
|
|
||||||
|
|
||||||
void ScreenRaveOptions::ImportOptions()
|
|
||||||
{
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
|
||||||
{
|
|
||||||
int iSuperGrowthIndex = (int)SCALE( GAMESTATE->m_fSuperMeterGrowthScale[p], 0.25f, 2.f, 0.f, 7.f );
|
|
||||||
CLAMP( iSuperGrowthIndex, 0, 9 );
|
|
||||||
m_iSelectedOption[p][RO_SUPER_GROWTH] = iSuperGrowthIndex;
|
|
||||||
}
|
|
||||||
|
|
||||||
m_iSelectedOption[0][RO_CPU_SKILL] = GAMESTATE->m_iCpuSkill[0];
|
|
||||||
CLAMP( m_iSelectedOption[0][RO_CPU_SKILL], 0, 10 );
|
|
||||||
}
|
|
||||||
|
|
||||||
void ScreenRaveOptions::ExportOptions()
|
|
||||||
{
|
|
||||||
int p;
|
|
||||||
for( p=0; p<NUM_PLAYERS; p++ )
|
|
||||||
GAMESTATE->m_fSuperMeterGrowthScale[p] = SCALE( m_iSelectedOption[p][RO_SUPER_GROWTH], 0.f, 7.f, 0.25f, 2.f );
|
|
||||||
for( p=0; p<NUM_PLAYERS; p++ )
|
|
||||||
GAMESTATE->m_iCpuSkill[p] = m_iSelectedOption[0][RO_CPU_SKILL];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScreenRaveOptions::GoToPrevState()
|
void ScreenRaveOptions::GoToPrevState()
|
||||||
|
|||||||
@@ -1,3 +1,5 @@
|
|||||||
|
#ifndef SCREENRAVEOPTIONS_H
|
||||||
|
#define SCREENRAVEOPTIONS_H
|
||||||
/*
|
/*
|
||||||
-----------------------------------------------------------------------------
|
-----------------------------------------------------------------------------
|
||||||
File: ScreenRaveOptions
|
File: ScreenRaveOptions
|
||||||
@@ -9,18 +11,16 @@
|
|||||||
-----------------------------------------------------------------------------
|
-----------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ScreenOptions.h"
|
#include "ScreenOptionsMaster.h"
|
||||||
|
|
||||||
class ScreenRaveOptions : public ScreenOptions
|
class ScreenRaveOptions : public ScreenOptionsMaster
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
ScreenRaveOptions( CString sName );
|
ScreenRaveOptions( CString sName );
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void ImportOptions();
|
|
||||||
void ExportOptions();
|
|
||||||
|
|
||||||
void GoToNextState();
|
void GoToNextState();
|
||||||
void GoToPrevState();
|
void GoToPrevState();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#endif
|
||||||
Reference in New Issue
Block a user