make GameButton an enum

This commit is contained in:
Glenn Maynard
2007-01-13 03:13:22 +00:00
parent 3fa0ecbc17
commit a4cf344876
3 changed files with 120 additions and 140 deletions
+3 -3
View File
@@ -46,10 +46,10 @@ GameInput Style::StyleInputToGameInput( int iCol, PlayerNumber pn ) const
if( bUsingOneSide && gc != (int) pn )
continue;
for( int i = GAME_BUTTON_NEXT; i < INPUTMAPPER->GetInputScheme()->m_iButtonsPerController && m_iInputColumn[gc][i-GAME_BUTTON_NEXT] != END_MAPPING; ++i )
for( GameButton gb=GAME_BUTTON_NEXT; gb < INPUTMAPPER->GetInputScheme()->m_iButtonsPerController && m_iInputColumn[gc][gb-GAME_BUTTON_NEXT] != END_MAPPING; gb=(GameButton)(gb+1) )
{
if( m_iInputColumn[gc][i-GAME_BUTTON_NEXT] == iCol )
return GameInput( gc, i );
if( m_iInputColumn[gc][gb-GAME_BUTTON_NEXT] == iCol )
return GameInput( gc, gb );
}
}