Use XToString2.

This commit is contained in:
Steve Checkoway
2006-10-15 00:00:22 +00:00
parent 5c88094731
commit 04bff6bc1d
34 changed files with 62 additions and 62 deletions
+2 -2
View File
@@ -37,7 +37,7 @@ static const char *HorizAlignNames[] = {
"Center",
"Right"
};
XToString( HorizAlign, NUM_HorizAlign );
XToString2( HorizAlign );
LuaXType( HorizAlign );
static const char *VertAlignNames[] = {
@@ -45,7 +45,7 @@ static const char *VertAlignNames[] = {
"Middle",
"Bottom"
};
XToString( VertAlign, NUM_VertAlign );
XToString2( VertAlign );
LuaXType( VertAlign );
void Actor::SetBGMTime( float fTime, float fBeat )
+1 -1
View File
@@ -606,7 +606,7 @@ static const char *FileTypeNames[] = {
"Lua",
"Model",
};
XToString( FileType, NUM_FileType );
XToString2( FileType );
LuaXType( FileType );
FileType ActorUtil::GetFileType( const RString &sPath )
+1 -1
View File
@@ -52,7 +52,7 @@ const char *CodeNames[] = {
"CancelAllPlayerOptions",
"BackInEventMode",
};
XToString( Code, NUM_Code );
XToString2( Code );
static CodeItem g_CodeItems[NUM_Code];
+1 -1
View File
@@ -15,7 +15,7 @@ static const char *ControllerStateButtonNames[] = {
"Left",
"Right",
};
XToString( ControllerStateButton, NUM_ControllerStateButton );
XToString2( ControllerStateButton );
static const DeviceButton ControllerStateButtonToDeviceButton[] = {
JOY_UP,
+2 -2
View File
@@ -25,7 +25,7 @@ static const char *CourseTypeNames[] = {
"Endless",
"Survival",
};
XToString( CourseType, NUM_CourseType );
XToString2( CourseType );
XToLocalizedString( CourseType );
LuaXType( CourseType );
LuaFunction( CourseTypeToLocalizedString, CourseTypeToLocalizedString( Enum::Check<CourseType>( L, 1 ) ) );
@@ -38,7 +38,7 @@ static const char *SongSortNames[] = {
"TopGrades",
"LowestGrades",
};
XToString( SongSort, NUM_SongSort );
XToString2( SongSort );
XToLocalizedString( SongSort );
+1 -1
View File
@@ -194,7 +194,7 @@ static const char *MonthNames[] =
"November",
"December",
};
XToString( Month, NUM_Month );
XToString2( Month );
XToLocalizedString( Month );
LuaXType( Month );
+1 -1
View File
@@ -14,7 +14,7 @@ static const char *DifficultyNames[] = {
"Challenge",
"Edit",
};
XToString( Difficulty, NUM_Difficulty );
XToString2( Difficulty );
XToLocalizedString( Difficulty );
LuaXType( Difficulty );
+2 -2
View File
@@ -24,7 +24,7 @@ static const char *EditMenuRowNames[] = {
"SourceSteps",
"Action"
};
XToString( EditMenuRow, NUM_EditMenuRow );
XToString2( EditMenuRow );
XToLocalizedString( EditMenuRow );
static const char *EditMenuActionNames[] = {
@@ -33,7 +33,7 @@ static const char *EditMenuActionNames[] = {
"Create",
"Practice",
};
XToString( EditMenuAction, NUM_EditMenuAction );
XToString2( EditMenuAction );
XToLocalizedString( EditMenuAction );
StringToX( EditMenuAction );
+17 -17
View File
@@ -28,7 +28,7 @@ static const char *RadarCategoryNames[] = {
"Hands",
"Rolls"
};
XToString( RadarCategory, NUM_RadarCategory );
XToString2( RadarCategory );
XToLocalizedString( RadarCategory );
LuaFunction( RadarCategoryToLocalizedString, RadarCategoryToLocalizedString(Enum::Check<RadarCategory>(L, 1)) );
LuaXType( RadarCategory );
@@ -58,7 +58,7 @@ static const char *PlayModeNames[] = {
"Battle",
"Rave",
};
XToString( PlayMode, NUM_PlayMode );
XToString2( PlayMode );
XToLocalizedString( PlayMode );
StringToX( PlayMode );
LuaFunction( PlayModeToLocalizedString, PlayModeToLocalizedString(Enum::Check<PlayMode>(L, 1)) );
@@ -79,7 +79,7 @@ static const char *RankingCategoryNames[] = {
"c",
"d",
};
XToString( RankingCategory, NUM_RankingCategory );
XToString2( RankingCategory );
StringToX( RankingCategory );
@@ -88,7 +88,7 @@ static const char *PlayerControllerNames[] = {
"Autoplay",
"Cpu",
};
XToString( PlayerController, NUM_PlayerController );
XToString2( PlayerController );
StringToX( PlayerController );
XToLocalizedString( PlayerController );
LuaXType( PlayerController );
@@ -99,7 +99,7 @@ static const char *CoinModeNames[] = {
"Pay",
"Free",
};
XToString( CoinMode, NUM_CoinMode );
XToString2( CoinMode );
StringToX( CoinMode );
LuaXType( CoinMode );
@@ -109,7 +109,7 @@ static const char *PremiumNames[] = {
"Double",
"Joint",
};
XToString( Premium, NUM_Premium );
XToString2( Premium );
StringToX( Premium );
LuaXType( Premium );
@@ -134,7 +134,7 @@ static const char *SortOrderNames[] = {
"Endless",
"Roulette",
};
XToString( SortOrder, NUM_SortOrder );
XToString2( SortOrder );
StringToX( SortOrder );
LuaXType( SortOrder );
@@ -150,7 +150,7 @@ static const char *TapNoteScoreNames[] = {
"W2",
"W1",
};
XToString( TapNoteScore, NUM_TapNoteScore );
XToString2( TapNoteScore );
LuaXType( TapNoteScore );
TapNoteScore StringToTapNoteScore( const RString &s )
{
@@ -183,7 +183,7 @@ static const char *HoldNoteScoreNames[] = {
"LetGo",
"Held",
};
XToString( HoldNoteScore, NUM_HoldNoteScore );
XToString2( HoldNoteScore );
LuaXType( HoldNoteScore );
HoldNoteScore StringToHoldNoteScore( const RString &s )
{
@@ -209,7 +209,7 @@ static const char *MemoryCardStateNames[] = {
"removed",
"none",
};
XToString( MemoryCardState, NUM_MemoryCardState );
XToString2( MemoryCardState );
static const char *PerDifficultyAwardNames[] = {
@@ -224,7 +224,7 @@ static const char *PerDifficultyAwardNames[] = {
"Percent90W3",
"Percent100W3",
};
XToString( PerDifficultyAward, NUM_PerDifficultyAward );
XToString2( PerDifficultyAward );
XToLocalizedString( PerDifficultyAward );
StringToX( PerDifficultyAward );
LuaFunction( PerDifficultyAwardToLocalizedString, PerDifficultyAwardToLocalizedString(Enum::Check<PerDifficultyAward>(L, 1)) );
@@ -246,7 +246,7 @@ static const char *PeakComboAwardNames[] = {
"Peak9000Combo",
"Peak10000Combo",
};
XToString( PeakComboAward, NUM_PeakComboAward );
XToString2( PeakComboAward );
XToLocalizedString( PeakComboAward );
StringToX( PeakComboAward );
LuaFunction( PeakComboAwardToLocalizedString, PeakComboAwardToLocalizedString(Enum::Check<PeakComboAward>(L, 1)) );
@@ -304,7 +304,7 @@ static const char *StyleTypeNames[] = {
"OnePlayerTwoSides",
"TwoPlayersSharedSides",
};
XToString( StyleType, NUM_StyleType );
XToString2( StyleType );
StringToX( StyleType );
LuaXType( StyleType );
@@ -314,7 +314,7 @@ static const char *GoalTypeNames[] = {
"Time",
"None",
};
XToString( GoalType, NUM_GoalType );
XToString2( GoalType );
StringToX( GoalType );
LuaXType( GoalType );
@@ -324,7 +324,7 @@ static const char *EditModeNames[] = {
"Home",
"Full"
};
XToString( EditMode, NUM_EditMode );
XToString2( EditMode );
StringToX( EditMode );
LuaXType( EditMode );
@@ -344,7 +344,7 @@ static const char *StageNames[] = {
"Event",
"Demo",
};
XToString( Stage, NUM_Stage );
XToString2( Stage );
LuaXType( Stage );
@@ -354,7 +354,7 @@ static const char *MultiPlayerStatusNames[] = {
"Unplugged",
"MissingMultitap",
};
XToString( MultiPlayerStatus, NUM_MultiPlayerStatus );
XToString2( MultiPlayerStatus );
/*
+1 -1
View File
@@ -10,7 +10,7 @@ static const char *GameControllerNames[] = {
"Controller1",
"Controller2",
};
XToString( GameController, NUM_GameController );
XToString2( GameController );
StringToX( GameController );
+2 -2
View File
@@ -33,7 +33,7 @@ static const char *CabinetLightNames[] = {
"BassLeft",
"BassRight",
};
XToString( CabinetLight, NUM_CabinetLight );
XToString2( CabinetLight );
StringToX( CabinetLight );
static const char *LightsModeNames[] = {
@@ -47,7 +47,7 @@ static const char *LightsModeNames[] = {
"TestAutoCycle",
"TestManualCycle",
};
XToString( LightsMode, NUM_LightsMode );
XToString2( LightsMode );
static void GetUsedGameInputs( vector<GameInput> &vGameInputsOut )
{
+1 -1
View File
@@ -16,7 +16,7 @@ static const char *MenuButtonNames[] =
"Coin",
"Operator"
};
XToString( MenuButton, NUM_MenuButton );
XToString2( MenuButton );
XToLocalizedString( MenuButton );
+1 -1
View File
@@ -133,7 +133,7 @@ static const char *MessageNames[] = {
"ShowHoldJudgmentMuliPlayerP31",
"ShowHoldJudgmentMuliPlayerP32",
};
XToString( Message, NUM_Message );
XToString2( Message );
static RageMutex g_Mutex( "MessageManager" );
+3 -3
View File
@@ -26,7 +26,7 @@ static const char *NotePartNames[] = {
"HoldBottomCap",
"HoldTail",
};
XToString( NotePart, NUM_NotePart );
XToString2( NotePart );
static const RageVector2 g_emptyVector = RageVector2( 0, 0 );
@@ -234,13 +234,13 @@ static const char *HoldTypeNames[] = {
"hold",
"roll",
};
XToString( HoldType, NUM_HoldType );
XToString2( HoldType );
static const char *ActiveTypeNames[] = {
"active",
"inactive",
};
XToString( ActiveType, NUM_ActiveType );
XToString2( ActiveType );
+1 -1
View File
@@ -27,7 +27,7 @@ static const char *NoteTypeNames[] = {
"64th",
"192nd",
};
XToString( NoteType, NUM_NoteType );
XToString2( NoteType );
LuaXType( NoteType )
XToLocalizedString( NoteType );
+2 -2
View File
@@ -33,14 +33,14 @@ static const char *SelectTypeNames[] = {
"SelectMultiple",
"SelectNone",
};
XToString( SelectType, NUM_SelectType );
XToString2( SelectType );
StringToX( SelectType );
static const char *LayoutTypeNames[] = {
"ShowAllInRow",
"ShowOneInRow",
};
XToString( LayoutType, NUM_LayoutType );
XToString2( LayoutType );
StringToX( LayoutType );
RString OptionRowHandler::OptionTitle() const
+2 -2
View File
@@ -8,7 +8,7 @@ static const char *PlayerNumberNames[] = {
"P1",
"P2",
};
XToString( PlayerNumber, NUM_PlayerNumber );
XToString2( PlayerNumber );
XToLocalizedString( PlayerNumber );
LuaFunction( PlayerNumberToString, PlayerNumberToString(Enum::Check<PlayerNumber>(L, 1)) );
LuaXType( PlayerNumber );
@@ -47,7 +47,7 @@ static const char *MultiPlayerNames[] = {
"P31",
"P32",
};
XToString( MultiPlayer, NUM_MultiPlayer );
XToString2( MultiPlayer );
XToLocalizedString( MultiPlayer );
LuaFunction( MultiPlayerToString, MultiPlayerToString(Enum::Check<MultiPlayer>(L, 1)) );
LuaFunction( MultiPlayerToLocalizedString, MultiPlayerToLocalizedString(Enum::Check<MultiPlayer>(L, 1)) );
+2 -2
View File
@@ -29,7 +29,7 @@ static const char *TimingWindowNames[] = {
"Hold",
"Roll",
};
XToString( TimingWindow, NUM_TimingWindow );
XToString2( TimingWindow );
static const char *ScoreEventNames[] = {
@@ -43,7 +43,7 @@ static const char *ScoreEventNames[] = {
"Held",
"LetGo",
};
XToString( ScoreEvent, NUM_ScoreEvent );
XToString2( ScoreEvent );
static const char *MusicWheelUsesSectionsNames[] = {
+1 -1
View File
@@ -66,7 +66,7 @@ static const char *PixelFormatNames[] = {
"BGR8",
"A1BGR5",
};
XToString( PixelFormat, NUM_PixelFormat );
XToString2( PixelFormat );
/* bNeedReloadTextures is set to true if the device was re-created and we need
* to reload textures. On failure, an error message is returned.
+1 -1
View File
@@ -211,7 +211,7 @@ static const char *InputDeviceNames[] = {
"Pump2",
"Midi",
};
XToString( InputDevice, NUM_InputDevice );
XToString2( InputDevice );
StringToX( InputDevice );
/* Return a reversible representation of a DeviceInput. This is not affected by InputDrivers,
+1 -1
View File
@@ -82,7 +82,7 @@ static const char *EditStateNames[] = {
"RecordPaused",
"Playing"
};
XToString( EditState, NUM_EditState );
XToString2( EditState );
#if defined(XBOX)
void ScreenEdit::InitEditMappings()
+2 -2
View File
@@ -40,14 +40,14 @@ static const char *JudgeLineNames[] =
{
"W1", "W2", "W3", "W4", "W5", "Miss", "Held", "MaxCombo"
};
XToString( JudgeLine, NUM_JudgeLine );
XToString2( JudgeLine );
#define FOREACH_JudgeLine( rc ) FOREACH_ENUM( JudgeLine, rc )
static const char *StatLineNames[NUM_StatLine] =
{
"Jumps", "Holds", "Mines", "Hands", "Rolls",
};
XToString( StatLine, NUM_StatLine );
XToString2( StatLine );
#define FOREACH_StatLine( rc ) FOREACH_ENUM( StatLine, rc )
#define CHEER_DELAY_SECONDS THEME->GetMetricF(m_sName,"CheerDelaySeconds")
+1 -1
View File
@@ -34,7 +34,7 @@ static const char *CourseEntryActionNames[] = {
"Insert Entry",
"Delete",
};
XToString( CourseEntryAction, NUM_CourseEntryAction );
XToString2( CourseEntryAction );
#define FOREACH_CourseEntryAction( i ) FOREACH_ENUM( CourseEntryAction, i )
static MenuDef g_TempMenu(
+1 -1
View File
@@ -121,7 +121,7 @@ static const char *CourseActionNames[] = {
"Rename",
"Delete",
};
XToString( CourseAction, NUM_CourseAction );
XToString2( CourseAction );
#define FOREACH_CourseAction( i ) FOREACH_ENUM( CourseAction, i )
static MenuDef g_TempMenu(
@@ -36,7 +36,7 @@ static const char *StepsEditActionNames[] = {
"Rename",
"Delete",
};
XToString( StepsEditAction, NUM_StepsEditAction );
XToString2( StepsEditAction );
#define FOREACH_StepsEditAction( i ) FOREACH_ENUM( StepsEditAction, i )
static MenuDef g_TempMenu(
@@ -40,7 +40,7 @@ static const char *ProfileActionNames[] = {
"Delete",
"Clear",
};
XToString( ProfileAction, NUM_ProfileAction );
XToString2( ProfileAction );
XToLocalizedString( ProfileAction );
#define FOREACH_ProfileAction( i ) FOREACH_ENUM( ProfileAction, i )
@@ -27,7 +27,7 @@ static const char *ManageWorkoutsActionNames[] = {
"Rename",
"Delete",
};
XToString( ManageWorkoutsAction, NUM_ManageWorkoutsAction );
XToString2( ManageWorkoutsAction );
#define FOREACH_ManageWorkoutsAction( i ) FOREACH_ENUM( ManageWorkoutsAction, i )
static MenuDef g_TempMenu(
+1 -1
View File
@@ -18,7 +18,7 @@ static const char *PromptAnswerNames[] = {
"No",
"Cancel",
};
XToString( PromptAnswer, NUM_PromptAnswer );
XToString2( PromptAnswer );
/* Settings: */
namespace
+1 -1
View File
@@ -25,7 +25,7 @@ static const char *PageTypeNames[] = {
"SurvivalCourses",
"AllCourses",
};
XToString( PageType, NUM_PageType );
XToString2( PageType );
StringToX( PageType );
#define TYPE THEME->GetMetric(m_sName,"Type")
+1 -1
View File
@@ -21,7 +21,7 @@ static const char *MenuDirNames[] = {
"Right",
"Auto",
};
XToString( MenuDir, NUM_MenuDir );
XToString2( MenuDir );
AutoScreenMessage( SM_PlayPostSwitchPage )
+1 -1
View File
@@ -19,7 +19,7 @@ static const char *SetTimeSelectionNames[] = {
"Minute",
"Second",
};
XToString( SetTimeSelection, NUM_SetTimeSelection );
XToString2( SetTimeSelection );
#define FOREACH_SetTimeSelection( s ) FOREACH_ENUM( SetTimeSelection, s )
const float g_X[NUM_SetTimeSelection] =
+1 -1
View File
@@ -36,7 +36,7 @@ static const char *ElementCategoryNames[] = {
"Sounds",
"Other"
};
XToString( ElementCategory, NUM_ElementCategory );
XToString2( ElementCategory );
StringToX( ElementCategory );
+2 -2
View File
@@ -33,7 +33,7 @@ static const char *UnlockRequirementNames[] =
"Toasties",
"StagesCleared"
};
XToString( UnlockRequirement, NUM_UnlockRequirement );
XToString2( UnlockRequirement );
StringToX( UnlockRequirement );
LuaXType( UnlockRequirement );
@@ -44,7 +44,7 @@ static const char *UnlockRewardTypeNames[] =
"Course",
"Modifier",
};
XToString( UnlockRewardType, NUM_UnlockRewardType );
XToString2( UnlockRewardType );
XToLocalizedString( UnlockRewardType );
LuaXType( UnlockRewardType );
LuaFunction( UnlockRewardTypeToLocalizedString, UnlockRewardTypeToLocalizedString(Enum::Check<UnlockRewardType>(L, 1)) );
+2 -2
View File
@@ -16,7 +16,7 @@ static const char *WorkoutProgramNames[] = {
"Runner",
"Flat",
};
XToString( WorkoutProgram, NUM_WorkoutProgram );
XToString2( WorkoutProgram );
StringToX( WorkoutProgram );
XToLocalizedString( WorkoutProgram );
@@ -25,7 +25,7 @@ static const char *WorkoutStepsTypeNames[] = {
"NormalSteps",
"WorkoutSteps"
};
XToString( WorkoutStepsType, NUM_WorkoutStepsType );
XToString2( WorkoutStepsType );
StringToX( WorkoutStepsType );
XToLocalizedString( WorkoutStepsType );
LuaXType( WorkoutStepsType );