naming cleanups
This commit is contained in:
@@ -53,9 +53,9 @@ const char *CodeNames[] = {
|
||||
"CancelAllPlayerOptions",
|
||||
"BackInEventMode",
|
||||
};
|
||||
XToString( Code, NUM_CODES );
|
||||
XToString( Code, NUM_Code );
|
||||
|
||||
static CodeItem g_CodeItems[NUM_CODES];
|
||||
static CodeItem g_CodeItems[NUM_Code];
|
||||
|
||||
|
||||
bool CodeItem::EnteredCode( GameController controller ) const
|
||||
|
||||
@@ -45,9 +45,9 @@ enum Code {
|
||||
CODE_SAVE_SCREENSHOT2,
|
||||
CODE_CANCEL_ALL_PLAYER_OPTIONS,
|
||||
CODE_BACK_IN_EVENT_MODE,
|
||||
NUM_CODES // leave this at the end
|
||||
NUM_Code // leave this at the end
|
||||
};
|
||||
#define FOREACH_Code( c ) FOREACH_ENUM( Code, NUM_CODES, c )
|
||||
#define FOREACH_Code( c ) FOREACH_ENUM( Code, NUM_Code, c )
|
||||
|
||||
struct CodeItem
|
||||
{
|
||||
|
||||
@@ -77,7 +77,7 @@ static const char *RankingCategoryNames[] = {
|
||||
"c",
|
||||
"d",
|
||||
};
|
||||
XToString( RankingCategory, NUM_RANKING_CATEGORIES );
|
||||
XToString( RankingCategory, NUM_RankingCategory );
|
||||
StringToX( RankingCategory );
|
||||
|
||||
|
||||
|
||||
@@ -236,10 +236,10 @@ enum RankingCategory
|
||||
RANKING_B, // 4-6 meter per song avg.
|
||||
RANKING_C, // 7-9 meter per song avg.
|
||||
RANKING_D, // 10+ meter per song avg. // doesn't count extra stage!
|
||||
NUM_RANKING_CATEGORIES,
|
||||
RANKING_INVALID
|
||||
NUM_RankingCategory,
|
||||
RankingCategory_Invalid
|
||||
};
|
||||
#define FOREACH_RankingCategory( rc ) FOREACH_ENUM( RankingCategory, NUM_RANKING_CATEGORIES, rc )
|
||||
#define FOREACH_RankingCategory( rc ) FOREACH_ENUM( RankingCategory, NUM_RankingCategory, rc )
|
||||
const RString& RankingCategoryToString( RankingCategory rc );
|
||||
RankingCategory StringToRankingCategory( const RString& rc );
|
||||
|
||||
|
||||
@@ -33,14 +33,14 @@ static const char *SelectTypeNames[] = {
|
||||
"SelectMultiple",
|
||||
"SelectNone",
|
||||
};
|
||||
XToString( SelectType, NUM_SELECT_TYPES );
|
||||
XToString( SelectType, NUM_SelectType );
|
||||
StringToX( SelectType );
|
||||
|
||||
static const char *LayoutTypeNames[] = {
|
||||
"ShowAllInRow",
|
||||
"ShowOneInRow",
|
||||
};
|
||||
XToString( LayoutType, NUM_LAYOUT_TYPES );
|
||||
XToString( LayoutType, NUM_LayoutType );
|
||||
StringToX( LayoutType );
|
||||
|
||||
RString OptionRowHandler::OptionTitle() const
|
||||
@@ -820,7 +820,7 @@ public:
|
||||
if( pStr == NULL )
|
||||
RageException::Throw( "\"%s\" \"LayoutType\" entry is not a string.", sLuaFunction.c_str() );
|
||||
m_Def.m_layoutType = StringToLayoutType( pStr );
|
||||
ASSERT( m_Def.m_layoutType != LAYOUT_INVALID );
|
||||
ASSERT( m_Def.m_layoutType != LayoutType_Invalid );
|
||||
lua_pop( L, 1 );
|
||||
|
||||
|
||||
@@ -830,7 +830,7 @@ public:
|
||||
if( pStr == NULL )
|
||||
RageException::Throw( "\"%s\" \"SelectType\" entry is not a string.", sLuaFunction.c_str() );
|
||||
m_Def.m_selectType = StringToSelectType( pStr );
|
||||
ASSERT( m_Def.m_selectType != SELECT_INVALID );
|
||||
ASSERT( m_Def.m_selectType != SelectType_Invalid );
|
||||
lua_pop( L, 1 );
|
||||
|
||||
|
||||
|
||||
@@ -16,8 +16,8 @@ enum SelectType
|
||||
SELECT_ONE,
|
||||
SELECT_MULTIPLE,
|
||||
SELECT_NONE,
|
||||
NUM_SELECT_TYPES,
|
||||
SELECT_INVALID
|
||||
NUM_SelectType,
|
||||
SelectType_Invalid
|
||||
};
|
||||
const RString& SelectTypeToString( SelectType pm );
|
||||
SelectType StringToSelectType( const RString& s );
|
||||
@@ -26,8 +26,8 @@ enum LayoutType
|
||||
{
|
||||
LAYOUT_SHOW_ALL_IN_ROW,
|
||||
LAYOUT_SHOW_ONE_IN_ROW,
|
||||
NUM_LAYOUT_TYPES,
|
||||
LAYOUT_INVALID
|
||||
NUM_LayoutType,
|
||||
LayoutType_Invalid
|
||||
};
|
||||
const RString& LayoutTypeToString( LayoutType pm );
|
||||
LayoutType StringToLayoutType( const RString& s );
|
||||
|
||||
@@ -47,7 +47,7 @@ void PlayerStageStats::Init()
|
||||
m_pcaToShow = PEAK_COMBO_AWARD_INVALID;
|
||||
m_iPersonalHighScoreIndex = -1;
|
||||
m_iMachineHighScoreIndex = -1;
|
||||
m_rc = RANKING_INVALID;
|
||||
m_rc = RankingCategory_Invalid;
|
||||
m_HighScore = HighScore();
|
||||
}
|
||||
|
||||
|
||||
@@ -1536,7 +1536,7 @@ void Profile::LoadCategoryScoresFromNode( const XNode* pCategoryScores )
|
||||
if( !pRadarCategory->GetAttrValue( "Type", str ) )
|
||||
WARN_AND_CONTINUE;
|
||||
RankingCategory rc = StringToRankingCategory( str );
|
||||
if( rc == RANKING_INVALID )
|
||||
if( rc == RankingCategory_Invalid )
|
||||
WARN_AND_CONTINUE_M( str );
|
||||
|
||||
const XNode *pHighScoreListNode = pRadarCategory->GetChild("HighScoreList");
|
||||
|
||||
@@ -199,7 +199,7 @@ public:
|
||||
//
|
||||
// Category high scores
|
||||
//
|
||||
HighScoreList m_CategoryHighScores[NUM_StepsType][NUM_RANKING_CATEGORIES];
|
||||
HighScoreList m_CategoryHighScores[NUM_StepsType][NUM_RankingCategory];
|
||||
|
||||
void AddCategoryHighScore( StepsType st, RankingCategory rc, HighScore hs, int &iIndexOut );
|
||||
HighScoreList& GetCategoryHighScoreList( StepsType st, RankingCategory rc );
|
||||
|
||||
@@ -543,7 +543,7 @@ void ScreenRankingLines::Init()
|
||||
|
||||
for( unsigned i=0; i<STEPS_TYPES_TO_SHOW.GetValue().size(); i++ )
|
||||
{
|
||||
for( int c=0; c<NUM_RANKING_CATEGORIES; c++ )
|
||||
for( int c=0; c<NUM_RankingCategory; c++ )
|
||||
{
|
||||
PageToShow pts;
|
||||
pts.colorIndex = i;
|
||||
|
||||
Reference in New Issue
Block a user