add multiselect toggle sounds

This commit is contained in:
Chris Danford
2004-01-10 21:34:18 +00:00
parent 234b574970
commit ba9959205d
4 changed files with 10 additions and 0 deletions
+6
View File
@@ -93,6 +93,8 @@ ScreenOptions::ScreenOptions( CString sClassName ) : Screen(sClassName)
m_SoundNextRow.Load( THEME->GetPathToS("ScreenOptions next"), true );
m_SoundPrevRow.Load( THEME->GetPathToS("ScreenOptions prev"), true );
m_SoundStart.Load( THEME->GetPathToS("Common start") );
m_SoundToggleOn.Load( THEME->GetPathToS("ScreenOptions toggle on") );
m_SoundToggleOff.Load( THEME->GetPathToS("ScreenOptions toggle off") );
m_Menu.Load( sClassName );
this->AddChild( &m_Menu );
@@ -1107,6 +1109,10 @@ void ScreenOptions::MenuStart( PlayerNumber pn, const InputEventType type )
{
int iChoiceInRow = row.m_iChoiceWithFocus[pn];
row.m_vbSelected[pn][iChoiceInRow] ^= true;
if( row.m_vbSelected[pn][iChoiceInRow] )
m_SoundToggleOn.Play();
else
m_SoundToggleOff.Play();
}
else
{