Playback enable/disable for attack and mine sounds

This commit is contained in:
Mike Hawkins
2008-05-10 19:10:22 +00:00
parent 52a33f48a6
commit 7d67bae8e0
3 changed files with 18 additions and 6 deletions
+11 -6
View File
@@ -593,11 +593,13 @@ void Player::Update( float fDeltaTime )
// if the Player doesn't show anything on the screen.
if( HasVisibleParts() )
{
if( m_pPlayerState->m_bAttackBeganThisUpdate )
m_soundAttackLaunch.Play();
if( m_pPlayerState->m_bAttackEndedThisUpdate )
m_soundAttackEnding.Play();
if( PREFSMAN->m_bEnableAttackSoundPlayback )
{
if( m_pPlayerState->m_bAttackBeganThisUpdate )
m_soundAttackLaunch.Play();
if( m_pPlayerState->m_bAttackEndedThisUpdate )
m_soundAttackEnding.Play();
}
if( m_pNoteField )
m_pNoteField->Update( fDeltaTime );
@@ -2289,7 +2291,10 @@ void Player::UpdateJudgedRows()
if( tn.iKeysoundIndex >= 0 && tn.iKeysoundIndex < (int) m_vKeysounds.size() )
setSounds.insert( &m_vKeysounds[tn.iKeysoundIndex] );
else
setSounds.insert( &m_soundMine );
{
if( PREFSMAN->m_bEnableMineSoundPlayback )
setSounds.insert( &m_soundMine );
}
ChangeLife( tn.result.tns );
if( m_pScoreDisplay )
+3
View File
@@ -229,6 +229,9 @@ PrefsManager::PrefsManager() :
m_bTrilinearFiltering ( "TrilinearFiltering", false ),
m_bAnisotropicFiltering ( "AnisotropicFiltering", false ),
m_bEnableAttackSoundPlayback ( "EnableAttackSounds", true ),
m_bEnableMineSoundPlayback ( "EnableMineHitSound", true ),
m_bSignProfileData ( "SignProfileData", false ),
m_CourseSortOrder ( "CourseSortOrder", COURSE_SORT_SONGS ),
m_bSubSortByNumSteps ( "SubSortByNumSteps", false ),
+4
View File
@@ -186,6 +186,10 @@ public:
Preference<bool> m_bCelShadeModels;
Preference<bool> m_bPreferredSortUsesGroups;
// Options to enable/disable the playback of attack start/end sounds, and mine hit sounds
Preference<bool> m_bEnableAttackSoundPlayback;
Preference<bool> m_bEnableMineSoundPlayback;
// Number of seconds it takes for a button on the controller to release
// after pressed.
Preference<float> m_fPadStickSeconds;