Add StringTo<TapNoteScore>. (Normally this would be part of the StringToX macro.

This commit is contained in:
Steve Checkoway
2006-07-03 04:29:41 +00:00
parent 16a1301fae
commit 227d2d1575
+5 -1
View File
@@ -197,7 +197,7 @@ XToString( TapNoteScore, NUM_TapNoteScore );
TapNoteScore StringToTapNoteScore( const RString &s )
{
// new style
if ( s == "None" ) return TNS_None;
if ( s == "None" ) return TNS_None;
else if( s == "HitMine" ) return TNS_HitMine;
else if( s == "AvoidMine" ) return TNS_AvoidMine;
else if( s == "Miss" ) return TNS_Miss;
@@ -216,6 +216,10 @@ TapNoteScore StringToTapNoteScore( const RString &s )
return TNS_INVALID;
}
template<> void StringTo<TapNoteScore>( const RString &s, TapNoteScore &out )
{
out = StringToTapNoteScore( s );
}
XToLocalizedString( TapNoteScore );
LuaFunction( TapNoteScoreToLocalizedString, TapNoteScoreToLocalizedString((TapNoteScore) IArg(1)) );
static void LuaTapNoteScores( lua_State* L )