Merge pull request #486 from kyzentun/mute_actions

Toggle key for muting actions
This commit is contained in:
Kyzentun
2015-03-07 17:51:28 -07:00
38 changed files with 165 additions and 131 deletions
+1 -1
View File
@@ -14,7 +14,7 @@ void ActorSound::Load( const RString &sPath )
void ActorSound::Play()
{
m_Sound.Play();
m_Sound.Play(false);
}
void ActorSound::Pause( bool bPause )
+4 -4
View File
@@ -316,7 +316,7 @@ void EditMenu::Up()
} while (!RowIsSelectable(dest));
ASSERT( dest >= 0 );
ChangeToRow( dest );
m_soundChangeRow.Play();
m_soundChangeRow.Play(true);
}
void EditMenu::Down()
@@ -328,7 +328,7 @@ void EditMenu::Down()
} while (!RowIsSelectable(dest));
ASSERT( dest < NUM_EditMenuRow );
ChangeToRow( dest );
m_soundChangeRow.Play();
m_soundChangeRow.Play(true);
}
void EditMenu::Left()
@@ -338,7 +338,7 @@ void EditMenu::Left()
m_iSelection[m_SelectedRow]--;
wrap( m_iSelection[m_SelectedRow], GetRowSize(m_SelectedRow) );
OnRowValueChanged( m_SelectedRow );
m_soundChangeValue.Play();
m_soundChangeValue.Play(true);
}
}
@@ -349,7 +349,7 @@ void EditMenu::Right()
m_iSelection[m_SelectedRow]++;
wrap( m_iSelection[m_SelectedRow], GetRowSize(m_SelectedRow) );
OnRowValueChanged( m_SelectedRow );
m_soundChangeValue.Play();
m_soundChangeValue.Play(true);
}
}
+1 -1
View File
@@ -276,7 +276,7 @@ static void DoPlayOnce( RString sPath )
RageSound *pSound = new RageSound;
pSound->Load( sPath, false );
pSound->Play();
pSound->Play(false);
pSound->DeleteSelfWhenFinishedPlaying();
}
+3 -3
View File
@@ -59,7 +59,7 @@ void GameplayAssist::PlayTicks( const NoteData &nd, const PlayerState *ps )
RageSoundParams p;
p.m_StartTime = position.m_LastBeatUpdate + (fSecondsUntil - (float)CommonMetrics::TICK_EARLY_SECONDS);
m_soundAssistClap.Play( &p );
m_soundAssistClap.Play(false, &p);
}
}
@@ -96,9 +96,9 @@ void GameplayAssist::PlayTicks( const NoteData &nd, const PlayerState *ps )
RageSoundParams p;
p.m_StartTime = position.m_LastBeatUpdate + (fSecondsUntil - (float)CommonMetrics::TICK_EARLY_SECONDS);
if( bIsMeasure )
m_soundAssistMetronomeMeasure.Play( &p );
m_soundAssistMetronomeMeasure.Play(false, &p);
else
m_soundAssistMetronomeBeat.Play( &p );
m_soundAssistMetronomeBeat.Play(false, &p);
}
}
+3 -3
View File
@@ -92,7 +92,7 @@ void Inventory::Load( PlayerState* pPlayerState )
void Inventory::Update( float fDelta )
{
if( m_pPlayerState->m_bAttackEndedThisUpdate )
m_soundItemEnding.Play();
m_soundItemEnding.Play(false);
// TODO: remove use of PlayerNumber
PlayerNumber pn = m_pPlayerState->m_PlayerNumber;
@@ -183,7 +183,7 @@ void Inventory::AwardItem( int iItemIndex )
a.fSecsRemaining = ITEM_DURATION_SECONDS;
a.level = g_Items[iItemIndex].level;
pInventory[iOpenSlot] = a;
m_soundAcquireItem.Play();
m_soundAcquireItem.Play(false);
}
// else not enough room to insert item
}
@@ -200,7 +200,7 @@ void Inventory::UseItem( int iSlot )
// remove the item
pInventory[iSlot].MakeBlank();
m_vpSoundUseItem[a.level]->Play();
m_vpSoundUseItem[a.level]->Play(false);
PlayerNumber pnToAttack = OPPOSITE_PLAYER[pn];
PlayerState *pPlayerStateToAttack = GAMESTATE->m_pPlayerState[pnToAttack];
+3 -3
View File
@@ -107,7 +107,7 @@ void LifeMeterBattery::OnSongEnded()
m_iLivesLeft = min( m_iLivesLeft, m_pPlayerState->m_PlayerOptions.GetSong().m_BatteryLives );
if( m_iTrailingLivesLeft < m_iLivesLeft )
m_soundGainLife.Play();
m_soundGainLife.Play(false);
}
Refresh();
@@ -120,7 +120,7 @@ void LifeMeterBattery::SubtractLives( int iLives )
m_iTrailingLivesLeft = m_iLivesLeft;
m_iLivesLeft -= iLives;
m_soundLoseLife.Play();
m_soundLoseLife.Play(false);
m_textNumLives.PlayCommand("LoseLife");
Refresh();
@@ -135,7 +135,7 @@ void LifeMeterBattery::AddLives( int iLives )
m_iTrailingLivesLeft = m_iLivesLeft;
m_iLivesLeft += iLives;
m_soundGainLife.Play();
m_soundGainLife.Play(false);
m_textNumLives.PlayCommand("GainLife");
Refresh();
+1 -1
View File
@@ -128,7 +128,7 @@ void LifeMeterTime::OnLoadSong()
if( MIN_LIFE_TIME > fGainSeconds )
fGainSeconds = MIN_LIFE_TIME;
m_fLifeTotalGainedSeconds += fGainSeconds;
m_soundGainLife.Play();
m_soundGainLife.Play(false);
SendLifeChangedMessage( fOldLife, TapNoteScore_Invalid, HoldNoteScore_Invalid );
}
+4 -4
View File
@@ -481,18 +481,18 @@ void MemoryCardManager::CheckStateChanges()
case MemoryCardState_Removed:
if( LastState == MemoryCardState_Ready )
{
m_soundDisconnect.Play( &params );
m_soundDisconnect.Play(true, &params);
MESSAGEMAN->Broadcast( (MessageID)(Message_CardRemovedP1+p) );
}
break;
case MemoryCardState_Ready:
m_soundReady.Play( &params );
m_soundReady.Play(true, &params);
break;
case MemoryCardState_TooLate:
m_soundTooLate.Play( &params );
m_soundTooLate.Play(true, &params);
break;
case MemoryCardState_Error:
m_soundError.Play( &params );
m_soundError.Play(true, &params);
break;
default: break;
}
+1 -1
View File
@@ -110,7 +110,7 @@ void MenuTimer::Update( float fDeltaTime )
}
if( iCrossed <= WARNING_BEEP_START && m_soundBeep.IsLoaded() && !m_bSilent )
m_soundBeep.Play();
m_soundBeep.Play(false);
}
if( fNewSecondsLeft == 0 )
+2 -2
View File
@@ -1172,7 +1172,7 @@ void MusicWheel::ChangeMusic( int iDist )
// If we're moving automatically, don't play this; it'll be called in Update.
if(!IsMoving())
m_soundChangeMusic.Play();
m_soundChangeMusic.Play(true);
}
@@ -1201,7 +1201,7 @@ bool MusicWheel::ChangeSort( SortOrder new_so, bool allowSameSort ) // return tr
SCREENMAN->PostMessageToTopScreen( SM_SortOrderChanging, 0 );
m_soundChangeSort.Play();
m_soundChangeSort.Play(true);
TweenOffScreenForSort();
+5 -5
View File
@@ -850,9 +850,9 @@ void Player::Update( float fDeltaTime )
if( g_bEnableAttackSoundPlayback )
{
if( m_pPlayerState->m_bAttackBeganThisUpdate )
m_soundAttackLaunch.Play();
m_soundAttackLaunch.Play(false);
if( m_pPlayerState->m_bAttackEndedThisUpdate )
m_soundAttackEnding.Play();
m_soundAttackEnding.Play(false);
}
float fMiniPercent = m_pPlayerState->m_PlayerOptions.GetCurrent().m_fEffects[PlayerOptions::EFFECT_MINI];
@@ -1997,7 +1997,7 @@ void Player::PlayKeysound( const TapNote &tn, TapNoteScore score )
}
}
}
m_vKeysounds[tn.iKeysoundIndex].Play();
m_vKeysounds[tn.iKeysoundIndex].Play(false);
Preference<float> *pVolume = Preference<float>::GetPreferenceByName("SoundVolume");
float fVol = pVolume->Get();
m_vKeysounds[tn.iKeysoundIndex].SetProperty ("Volume", fVol);
@@ -2491,7 +2491,7 @@ void Player::StepStrumHopo( int col, int row, const RageTimer &tm, bool bHeld, b
{
score = TNS_None; // don't score this as anything
m_soundAttackLaunch.Play();
m_soundAttackLaunch.Play(false);
// put attack in effect
Attack attack(
@@ -2889,7 +2889,7 @@ void Player::UpdateJudgedRows()
{
// Only play one copy of each mine sound at a time per player.
(*s)->Stop();
(*s)->Play();
(*s)->Play(false);
}
}
}
+1
View File
@@ -286,6 +286,7 @@ PrefsManager::PrefsManager() :
m_bMonkeyInput ( "MonkeyInput", false ),
m_sMachineName ( "MachineName", "" ),
m_sCoursesToShowRanking ( "CoursesToShowRanking", "" ),
m_MuteActions("MuteActions", false),
m_bQuirksMode ( "QuirksMode", false ),
+1
View File
@@ -295,6 +295,7 @@ public:
Preference<bool> m_bMonkeyInput;
Preference<RString> m_sMachineName;
Preference<RString> m_sCoursesToShowRanking;
Preference<bool> m_MuteActions;
/** @brief Enable some quirky behavior used by some older versions of StepMania. */
Preference<bool> m_bQuirksMode;
+5 -1
View File
@@ -392,13 +392,17 @@ void RageSound::SoundIsFinishedPlaying()
m_Mutex.Unlock();
}
void RageSound::Play( const RageSoundParams *pParams )
void RageSound::Play(bool is_action, const RageSoundParams *pParams)
{
if( m_pSource == NULL )
{
LOG->Warn( "RageSound::Play: sound not loaded" );
return;
}
if(is_action && PREFSMAN->m_MuteActions)
{
return;
}
if( IsPlaying() )
{
+1 -1
View File
@@ -120,7 +120,7 @@ public:
RString GetError() const { return m_sError; }
void Play( const RageSoundParams *params=NULL );
void Play(bool is_action, const RageSoundParams *params=NULL);
void PlayCopy( const RageSoundParams *pParams = NULL ) const;
void Stop();
+1 -1
View File
@@ -106,7 +106,7 @@ void RandomSample::PlayRandom()
int iIndexToPlay = GetNextToPlay();
if( iIndexToPlay == -1 )
return;
m_pSamples[iIndexToPlay]->Play();
m_pSamples[iIndexToPlay]->Play(true);
}
void RandomSample::PlayCopyOfRandom()
+28 -3
View File
@@ -52,6 +52,8 @@ static const ThemeMetric<float> PAGE_SPACING_X ("ScreenDebugOverlay", "PageSpac
// We don't use SubscriptionManager, because we want to keep the line order.
static LocalizedString ON ( "ScreenDebugOverlay", "on" );
static LocalizedString OFF ( "ScreenDebugOverlay", "off" );
static LocalizedString MUTE_ACTIONS_ON ("ScreenDebugOverlay", "Mute actions on");
static LocalizedString MUTE_ACTIONS_OFF ("ScreenDebugOverlay", "Mute actions off");
class IDebugLine;
static vector<IDebugLine*> *g_pvpSubscribers = NULL;
@@ -113,6 +115,7 @@ struct MapDebugToDI
DeviceInput holdForDebug2;
DeviceInput holdForSlow;
DeviceInput holdForFast;
DeviceInput toggleMute;
DeviceInput debugButton[MAX_DEBUG_LINES];
DeviceInput gameplayButton[MAX_DEBUG_LINES];
map<DeviceInput, int> pageButton;
@@ -122,6 +125,7 @@ struct MapDebugToDI
holdForDebug2.MakeInvalid();
holdForSlow.MakeInvalid();
holdForFast.MakeInvalid();
toggleMute.MakeInvalid();
for( int i=0; i<MAX_DEBUG_LINES; i++ )
{
debugButton[i].MakeInvalid();
@@ -176,6 +180,7 @@ void ScreenDebugOverlay::Init()
g_Mappings.holdForDebug2.MakeInvalid();
g_Mappings.holdForSlow = DeviceInput(DEVICE_KEYBOARD, KEY_ACCENT);
g_Mappings.holdForFast = DeviceInput(DEVICE_KEYBOARD, KEY_TAB);
g_Mappings.toggleMute = DeviceInput(DEVICE_KEYBOARD, KEY_PAUSE);
/* TODO: Find a better way of indicating which option is which here.
* Maybe we should take a page from ScreenEdit's menus and make
@@ -206,9 +211,9 @@ void ScreenDebugOverlay::Init()
g_Mappings.debugButton[i++] = DeviceInput(DEVICE_KEYBOARD, KEY_Ci);
g_Mappings.debugButton[i++] = DeviceInput(DEVICE_KEYBOARD, KEY_Co);
g_Mappings.debugButton[i++] = DeviceInput(DEVICE_KEYBOARD, KEY_Cp);
g_Mappings.debugButton[i++] = DeviceInput(DEVICE_KEYBOARD, KEY_UP);
g_Mappings.debugButton[i++] = DeviceInput(DEVICE_KEYBOARD, KEY_DOWN);
g_Mappings.debugButton[i++] = DeviceInput(DEVICE_KEYBOARD, KEY_BACK);
g_Mappings.debugButton[i++] = DeviceInput(DEVICE_KEYBOARD, KEY_Ca);
g_Mappings.debugButton[i++] = DeviceInput(DEVICE_KEYBOARD, KEY_Cs);
g_Mappings.debugButton[i++] = DeviceInput(DEVICE_KEYBOARD, KEY_Cd);
g_Mappings.pageButton[DeviceInput(DEVICE_KEYBOARD, KEY_F5)] = 0;
g_Mappings.pageButton[DeviceInput(DEVICE_KEYBOARD, KEY_F6)] = 1;
g_Mappings.pageButton[DeviceInput(DEVICE_KEYBOARD, KEY_F7)] = 2;
@@ -438,6 +443,11 @@ bool ScreenDebugOverlay::Input( const InputEventPlus &input )
else
g_bIsDisplayed = false;
}
if(input.DeviceI == g_Mappings.toggleMute)
{
PREFSMAN->m_MuteActions.Set(!PREFSMAN->m_MuteActions);
SCREENMAN->SystemMessage(PREFSMAN->m_MuteActions ? MUTE_ACTIONS_ON.GetValue() : MUTE_ACTIONS_OFF.GetValue());
}
int iPage = 0;
if( g_bIsDisplayed && GetValueFromMap(g_Mappings.pageButton, input.DeviceI, iPage) )
@@ -546,6 +556,7 @@ static LocalizedString CLEAR_PROFILE_STATS ( "ScreenDebugOverlay", "Clear Profil
static LocalizedString FILL_PROFILE_STATS ( "ScreenDebugOverlay", "Fill Profile Stats" );
static LocalizedString SEND_NOTES_ENDED ( "ScreenDebugOverlay", "Send Notes Ended" );
static LocalizedString RESET_KEY_MAP ("ScreenDebugOverlay", "Reset key mapping to default");
static LocalizedString MUTE_ACTIONS ("ScreenDebugOverlay", "Mute actions");
static LocalizedString RELOAD ( "ScreenDebugOverlay", "Reload" );
static LocalizedString RESTART ( "ScreenDebugOverlay", "Restart" );
static LocalizedString SCREEN_ON ( "ScreenDebugOverlay", "Send On To Screen" );
@@ -967,6 +978,19 @@ class DebugLineResetKeyMapping : public IDebugLine
}
};
class DebugLineMuteActions : public IDebugLine
{
virtual RString GetDisplayTitle() { return MUTE_ACTIONS.GetValue(); }
virtual RString GetDisplayValue() { return RString(); }
virtual bool IsEnabled() { return PREFSMAN->m_MuteActions; }
virtual void DoAndLog( RString &sMessageOut )
{
PREFSMAN->m_MuteActions.Set(!PREFSMAN->m_MuteActions);
SCREENMAN->SystemMessage(PREFSMAN->m_MuteActions ? MUTE_ACTIONS_ON.GetValue() : MUTE_ACTIONS_OFF.GetValue());
IDebugLine::DoAndLog( sMessageOut );
}
};
class DebugLineReloadCurrentScreen : public IDebugLine
{
virtual RString GetDisplayTitle() { return RELOAD.GetValue(); }
@@ -1288,6 +1312,7 @@ DECLARE_ONE( DebugLineVisualDelayUp );
DECLARE_ONE( DebugLineForceCrash );
DECLARE_ONE( DebugLineUptime );
DECLARE_ONE( DebugLineResetKeyMapping );
DECLARE_ONE( DebugLineMuteActions );
/*
+20 -20
View File
@@ -2006,7 +2006,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
int iHeadRow;
if( m_NoteDataEdit.IsHoldNoteAtRow( iCol, iSongIndex, &iHeadRow ) )
{
m_soundRemoveNote.Play();
m_soundRemoveNote.Play(true);
SetDirty( true );
SaveUndo();
m_NoteDataEdit.SetTapNote( iCol, iHeadRow, TAP_EMPTY );
@@ -2014,7 +2014,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
}
else if( m_NoteDataEdit.GetTapNote(iCol, iSongIndex).type != TapNoteType_Empty )
{
m_soundRemoveNote.Play();
m_soundRemoveNote.Play(true);
SetDirty( true );
SaveUndo();
m_NoteDataEdit.SetTapNote( iCol, iSongIndex, TAP_EMPTY );
@@ -2027,7 +2027,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
}
else
{
m_soundAddNote.Play();
m_soundAddNote.Play(true);
SetDirty( true );
SaveUndo();
TapNote tn = m_selectedTap;
@@ -2107,7 +2107,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
if( fSpeeds[iSpeed] != fScrollSpeed )
{
m_soundMarker.Play();
m_soundMarker.Play(true);
fScrollSpeed = fSpeeds[iSpeed];
}
@@ -2238,7 +2238,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
m_NoteFieldEdit.m_iBeginMarker = iCurrentRow;
m_NoteFieldEdit.m_iEndMarker = -1;
}
m_soundMarker.Play();
m_soundMarker.Play(true);
}
return true;
case EDIT_BUTTON_OPEN_AREA_MENU:
@@ -2341,7 +2341,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
it - vSteps.begin() + 1,
int(vSteps.size()) );
SCREENMAN->SystemMessage( s );
m_soundSwitchSteps.Play();
m_soundSwitchSteps.Play(true);
ScrollTo( GetAppropriateTiming().GetBeatFromElapsedTime(curSecond) );
}
@@ -2374,7 +2374,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
{
GetAppropriateTimingForUpdate().AddSegment(BPMSegment(GetRow(), fNewBPM));
}
(fDelta>0 ? m_soundValueIncrease : m_soundValueDecrease).Play();
(fDelta>0 ? m_soundValueIncrease : m_soundValueDecrease).Play(true);
SetDirty( true );
}
return true;
@@ -2419,7 +2419,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
stops.erase( stops.begin()+i, stops.begin()+i+1);
}
(fDelta>0 ? m_soundValueIncrease : m_soundValueDecrease).Play();
(fDelta>0 ? m_soundValueIncrease : m_soundValueDecrease).Play(true);
SetDirty( true );
}
return true;
@@ -2465,7 +2465,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
stops.erase( stops.begin()+i, stops.begin()+i+1);
}
(fDelta>0 ? m_soundValueIncrease : m_soundValueDecrease).Play();
(fDelta>0 ? m_soundValueIncrease : m_soundValueDecrease).Play(true);
SetDirty( true );
}
return true;
@@ -2491,7 +2491,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
fDelta *= 40;
}
GetAppropriateTimingForUpdate().m_fBeat0OffsetInSeconds += fDelta;
(fDelta>0 ? m_soundValueIncrease : m_soundValueDecrease).Play();
(fDelta>0 ? m_soundValueIncrease : m_soundValueDecrease).Play(true);
if (GAMESTATE->m_bIsUsingStepTiming)
{
GAMESTATE->m_pCurSteps[PLAYER_1]->m_Attacks.UpdateStartTimes(fDelta);
@@ -2537,7 +2537,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
m_pSong->m_fMusicSampleStartSeconds += fDelta;
m_pSong->m_fMusicSampleStartSeconds = max(m_pSong->m_fMusicSampleStartSeconds,0);
}
(fDelta>0 ? m_soundValueIncrease : m_soundValueDecrease).Play();
(fDelta>0 ? m_soundValueIncrease : m_soundValueDecrease).Play(true);
SetDirty( true );
}
return true;
@@ -2822,7 +2822,7 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
}
bgChange.m_def.m_sFile1 = sName;
m_pSong->AddBackgroundChange( iLayer, bgChange );
m_soundMarker.Play();
m_soundMarker.Play(true);
}
}
return true;
@@ -2928,12 +2928,12 @@ bool ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
enum_add( m_InputPlayerNumber, 1 );
if( m_InputPlayerNumber == NUM_PLAYERS )
m_InputPlayerNumber = PLAYER_1;
m_soundSwitchPlayer.Play();
m_soundSwitchPlayer.Play(true);
return true;
case EDIT_BUTTON_SWITCH_TIMINGS:
GAMESTATE->m_bIsUsingStepTiming = !GAMESTATE->m_bIsUsingStepTiming;
m_soundSwitchTiming.Play();
m_soundSwitchTiming.Play(true);
return true;
default:
return false;
@@ -3347,7 +3347,7 @@ void ScreenEdit::TransitionEditState( EditState em )
p.m_StartSecond = fStartSeconds;
p.StopMode = RageSoundParams::M_CONTINUE;
m_pSoundMusic->SetProperty( "AccurateSync", true );
m_pSoundMusic->Play( &p );
m_pSoundMusic->Play(false, &p);
break;
}
default: break;
@@ -3419,7 +3419,7 @@ void ScreenEdit::ScrollTo( float fDestinationBeat )
}
}
m_soundChangeLine.Play();
m_soundChangeLine.Play(true);
}
static LocalizedString NEW_KEYSOUND_FILE("ScreenEdit", "Enter New Keysound File");
@@ -4240,7 +4240,7 @@ void ScreenEdit::HandleScreenMessage( const ScreenMessage SM )
void ScreenEdit::OnSnapModeChange()
{
m_soundChangeSnap.Play();
m_soundChangeSnap.Play(true);
NoteType nt = m_SnapDisplay.GetNoteType();
int iStepIndex = BeatToNoteRow( GetBeat() );
@@ -4535,7 +4535,7 @@ void ScreenEdit::HandleMainMenuChoice( MainMenuChoice c, const vector<int> &iAns
else
{
m_NoteFieldEdit.m_iBeginMarker = iCurrentRow;
m_soundMarker.Play();
m_soundMarker.Play(true);
}
}
break;
@@ -4549,7 +4549,7 @@ void ScreenEdit::HandleMainMenuChoice( MainMenuChoice c, const vector<int> &iAns
else
{
m_NoteFieldEdit.m_iEndMarker = iCurrentRow;
m_soundMarker.Play();
m_soundMarker.Play(true);
}
}
break;
@@ -4696,7 +4696,7 @@ void ScreenEdit::HandleMainMenuChoice( MainMenuChoice c, const vector<int> &iAns
break;
}
m_soundSave.Play();
m_soundSave.Play(true);
}
break;
case revert_to_last_save:
+1 -1
View File
@@ -773,7 +773,7 @@ bool ScreenEvaluation::MenuStart( const InputEventPlus &input )
if( IsTransitioning() )
return false;
m_soundStart.Play();
m_soundStart.Play(true);
HandleMenuStart();
return true;
+5 -5
View File
@@ -1477,7 +1477,7 @@ void ScreenGameplay::StartPlayingSong( float fMinTimeToNotes, float fMinTimeToMu
p.m_LengthSeconds = fSecondsToStartFadingOutMusic + MUSIC_FADE_OUT_SECONDS - p.m_StartSecond;
}
}
m_pSoundMusic->Play( &p );
m_pSoundMusic->Play(false, &p);
if( m_bPaused )
m_pSoundMusic->Pause( true );
@@ -1592,7 +1592,7 @@ void ScreenGameplay::BeginScreen()
p.StopMode = RageSoundParams::M_CONTINUE;
p.m_StartSecond = startOffset;
m_pSoundMusic->SetProperty( "AccurateSync", true );
m_pSoundMusic->Play( &p );
m_pSoundMusic->Play(false, &p);
UpdateSongPosition(0);
}
@@ -2854,9 +2854,9 @@ void ScreenGameplay::HandleScreenMessage( const ScreenMessage SM )
{
int iTrickLevel = SM-SM_BattleTrickLevel1+1;
PlayAnnouncer( ssprintf("gameplay battle trick level%d",iTrickLevel), 3 );
if( SM == SM_BattleTrickLevel1 ) m_soundBattleTrickLevel1.Play();
else if( SM == SM_BattleTrickLevel2 ) m_soundBattleTrickLevel2.Play();
else if( SM == SM_BattleTrickLevel3 ) m_soundBattleTrickLevel3.Play();
if( SM == SM_BattleTrickLevel1 ) m_soundBattleTrickLevel1.Play(false);
else if( SM == SM_BattleTrickLevel2 ) m_soundBattleTrickLevel2.Play(false);
else if( SM == SM_BattleTrickLevel3 ) m_soundBattleTrickLevel3.Play(false);
}
else if( SM >= SM_BattleDamageLevel1 && SM <= SM_BattleDamageLevel3 )
{
+1 -1
View File
@@ -866,7 +866,7 @@ void ScreenManager::ZeroNextUpdate()
{ \
RageSoundParams p; \
p.m_bIsCriticalSound = true; \
snd.Play(&p); \
snd.Play(false, &p); \
}
/* Always play these sounds, even if we're in a silent attract loop. */
+5 -5
View File
@@ -449,7 +449,7 @@ bool ScreenMapControllers::Input( const InputEventPlus &input )
INPUTMAPPER->AddDefaultMappingsForCurrentGameIfUnmapped();
m_soundDelete.Play();
m_soundDelete.Play(true);
bHandled = true;
}
break;
@@ -469,7 +469,7 @@ bool ScreenMapControllers::Input( const InputEventPlus &input )
--m_CurSlot;
}
AfterChangeFocus();
m_soundChange.Play();
m_soundChange.Play(true);
bHandled = true;
break;
case KEY_RIGHT: // Move the selection right, wrapping down.
@@ -485,7 +485,7 @@ bool ScreenMapControllers::Input( const InputEventPlus &input )
m_CurController++;
}
AfterChangeFocus();
m_soundChange.Play();
m_soundChange.Play(true);
bHandled = true;
break;
case KEY_UP: // Move the selection up.
@@ -496,7 +496,7 @@ bool ScreenMapControllers::Input( const InputEventPlus &input )
BeforeChangeFocus();
m_CurButton--;
AfterChangeFocus();
m_soundChange.Play();
m_soundChange.Play(true);
bHandled = true;
break;
case KEY_DOWN: // Move the selection down.
@@ -507,7 +507,7 @@ bool ScreenMapControllers::Input( const InputEventPlus &input )
BeforeChangeFocus();
m_CurButton++;
AfterChangeFocus();
m_soundChange.Play();
m_soundChange.Play(true);
bHandled = true;
break;
case KEY_ESC: // Quit the screen.
+2 -2
View File
@@ -352,7 +352,7 @@ bool ScreenNameEntry::Input( const InputEventPlus &input )
if( iStringIndex != -1 )
{
m_ReceptorArrowRow[input.pn].Step( iCol, TNS_W1 );
m_soundStep.Play();
m_soundStep.Play(true);
char c = m_Text[input.pn].GetClosestChar( m_fFakeBeat );
m_textSelectedChars[input.pn][iCol].SetText( RString(1, c) );
m_sSelectedName[input.pn][iStringIndex] = c;
@@ -391,7 +391,7 @@ bool ScreenNameEntry::MenuStart( const InputEventPlus &input )
m_bStillEnteringName[pn] = false;
m_Text[pn].SetDone();
m_soundStep.Play();
m_soundStep.Play(true);
// save last used ranking name
Profile* pProfile = PROFILEMAN->GetProfile(pn);
+9 -9
View File
@@ -811,7 +811,7 @@ bool ScreenOptions::MenuStart( const InputEventPlus &input )
if( bHoldingLeftAndRight )
{
if( MoveRowRelative(pn, -1, input.type != IET_FIRST_PRESS) )
m_SoundPrevRow.Play();
m_SoundPrevRow.Play(true);
return true;
}
}
@@ -902,9 +902,9 @@ void ScreenOptions::ProcessMenuStart( const InputEventPlus &input )
}
if( bSelected )
m_SoundToggleOn.Play();
m_SoundToggleOn.Play(true);
else
m_SoundToggleOff.Play();
m_SoundToggleOff.Play(true);
m_pRows[iCurRow]->PositionUnderlines( pn );
RefreshIcons( iCurRow, pn );
@@ -957,7 +957,7 @@ void ScreenOptions::ProcessMenuStart( const InputEventPlus &input )
/* Jump to the exit row. (If everyone's already on the exit row, then
* we'll have already gone to the next screen above.) */
if( MoveRowAbsolute(pn, m_pRows.size()-1) )
m_SoundNextRow.Play();
m_SoundNextRow.Play(true);
break;
}
@@ -1054,9 +1054,9 @@ void ScreenOptions::ChangeValueInRowRelative( int iRow, PlayerNumber pn, int iDe
if( MoveRowRelative(pn, iDelta, bRepeat) )
{
if( iDelta < 0 )
m_SoundPrevRow.Play();
m_SoundPrevRow.Play(true);
else
m_SoundNextRow.Play();
m_SoundNextRow.Play(true);
}
return;
}
@@ -1129,7 +1129,7 @@ void ScreenOptions::ChangeValueInRowRelative( int iRow, PlayerNumber pn, int iDe
}
if( bOneChanged )
m_SoundChangeCol.Play();
m_SoundChangeCol.Play(true);
if( row.GetRowDef().m_bExportOnChange )
{
@@ -1322,9 +1322,9 @@ void ScreenOptions::MenuUpDown( const InputEventPlus &input, int iDir )
if( MoveRowRelative(pn, iDir, input.type != IET_FIRST_PRESS) )
{
if( iDir < 0 )
m_SoundPrevRow.Play();
m_SoundPrevRow.Play(true);
else
m_SoundNextRow.Play();
m_SoundNextRow.Play(true);
}
}
+2 -2
View File
@@ -139,7 +139,7 @@ void ScreenOptionsCourseOverview::HandleScreenMessage( const ScreenMessage SM )
if( EditCourseUtil::RenameAndSave( GAMESTATE->m_pCurCourse, ScreenTextEntry::s_sLastAnswer ) )
{
m_soundSave.Play();
m_soundSave.Play(true);
SCREENMAN->SystemMessage( COURSE_SAVED );
}
}
@@ -236,7 +236,7 @@ void ScreenOptionsCourseOverview::ProcessMenuStart( const InputEventPlus &input
{
if( EditCourseUtil::Save( GAMESTATE->m_pCurCourse ) )
{
m_soundSave.Play();
m_soundSave.Play(true);
SCREENMAN->SystemMessage( COURSE_SAVED );
}
else
+1 -1
View File
@@ -217,7 +217,7 @@ bool ScreenOptionsManageCourses::MenuSelect( const InputEventPlus &input )
if( input.type != IET_FIRST_PRESS )
return false;
SetNextCombination();
m_soundDifficultyChanged.Play();
m_soundDifficultyChanged.Play(true);
return true;
}
+2 -2
View File
@@ -114,7 +114,7 @@ void ScreenOptionsCourseOverview::HandleScreenMessage( const ScreenMessage SM )
if( EditCourseUtil::RenameAndSave( GAMESTATE->m_pCurCourse, ScreenTextEntry::s_sLastAnswer ) )
{
m_soundSave.Play();
m_soundSave.Play(true);
SCREENMAN->SystemMessage( WORKOUT_SAVED );
}
}
@@ -169,7 +169,7 @@ void ScreenOptionsCourseOverview::ProcessMenuStart( const InputEventPlus &input
{
if( EditCourseUtil::Save( GAMESTATE->m_pCurCourse ) )
{
m_soundSave.Play();
m_soundSave.Play(true);
SCREENMAN->SystemMessage( WORKOUT_SAVED );
}
else
+1 -1
View File
@@ -160,7 +160,7 @@ void ScreenPrompt::Change( int dir )
PositionCursor();
m_sndChange.Play();
m_sndChange.Play(true);
}
bool ScreenPrompt::MenuLeft( const InputEventPlus &input )
+1 -1
View File
@@ -309,7 +309,7 @@ void ScreenSelectCharacter::Move( PlayerNumber pn, int deltaValue )
m_iSelectedCharacter[pnAffected] += deltaValue;
wrap( m_iSelectedCharacter[pnAffected], apCharacters.size() );
AfterValueChange(pn);
m_soundChange.Play();
m_soundChange.Play(true);
break;
}
default: break;
+1 -1
View File
@@ -50,7 +50,7 @@ bool ScreenSelectLanguage::MenuStart( const InputEventPlus &input )
PREFSMAN->SavePrefsToDisk();
THEME->SwitchThemeAndLanguage( THEME->GetCurThemeName(), PREFSMAN->m_sLanguage, PREFSMAN->m_bPseudoLocalize );
m_soundStart.Play();
m_soundStart.Play(true);
this->PostScreenMessage( SM_BeginFadingOut, 0 );
return true;
}
+4 -4
View File
@@ -540,7 +540,7 @@ bool ScreenSelectMaster::MenuLeft( const InputEventPlus &input )
if( Move(pn, MenuDir_Left) )
{
m_TrackingRepeatingInput = input.MenuI;
m_soundChange.Play();
m_soundChange.Play(true);
MESSAGEMAN->Broadcast( (MessageID)(Message_MenuLeftP1+pn) );
MESSAGEMAN->Broadcast( (MessageID)(Message_MenuSelectionChanged) );
@@ -571,7 +571,7 @@ bool ScreenSelectMaster::MenuRight( const InputEventPlus &input )
if( Move(pn, MenuDir_Right) )
{
m_TrackingRepeatingInput = input.MenuI;
m_soundChange.Play();
m_soundChange.Play(true);
MESSAGEMAN->Broadcast( (MessageID)(Message_MenuRightP1+pn) );
MESSAGEMAN->Broadcast( (MessageID)(Message_MenuSelectionChanged) );
@@ -602,7 +602,7 @@ bool ScreenSelectMaster::MenuUp( const InputEventPlus &input )
if( Move(pn, MenuDir_Up) )
{
m_TrackingRepeatingInput = input.MenuI;
m_soundChange.Play();
m_soundChange.Play(true);
MESSAGEMAN->Broadcast( (MessageID)(Message_MenuUpP1+pn) );
MESSAGEMAN->Broadcast( (MessageID)(Message_MenuSelectionChanged) );
@@ -633,7 +633,7 @@ bool ScreenSelectMaster::MenuDown( const InputEventPlus &input )
if( Move(pn, MenuDir_Down) )
{
m_TrackingRepeatingInput = input.MenuI;
m_soundChange.Play();
m_soundChange.Play(true);
MESSAGEMAN->Broadcast( (MessageID)(Message_MenuDownP1+pn) );
MESSAGEMAN->Broadcast( (MessageID)(Message_MenuSelectionChanged) );
+26 -26
View File
@@ -492,7 +492,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
m_bGoToOptions = true;
if( PLAY_SOUND_ON_ENTERING_OPTIONS_MENU )
m_soundStart.Play();
m_soundStart.Play(true);
this->PlayCommand( "ShowEnteringOptions" );
// Re-queue SM_BeginFadingOut, since ShowEnteringOptions may have
@@ -573,7 +573,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
if( MODE_MENU_AVAILABLE )
m_MusicWheel.NextSort();
else
m_soundLocked.Play();
m_soundLocked.Play(true);
break;
default: break;
}
@@ -679,14 +679,14 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
if (input.MenuI == m_GameButtonPreviousDifficulty )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
ChangeSteps( input.pn, -1 );
}
else if( input.MenuI == m_GameButtonNextDifficulty )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
ChangeSteps( input.pn, +1 );
}
@@ -705,7 +705,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
if(input.MenuI == m_GameButtonPreviousGroup )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
RString sNewGroup = m_MusicWheel.JumpToPrevGroup();
@@ -718,7 +718,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
else if(input.MenuI == m_GameButtonNextGroup )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
RString sNewGroup = m_MusicWheel.JumpToNextGroup();
@@ -740,7 +740,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
if( input.MenuI == m_GameButtonPreviousSong )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
m_SelectionState = SelectionState_SelectingSong;
@@ -752,7 +752,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
else if( input.MenuI == m_GameButtonNextSong )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
m_SelectionState = SelectionState_SelectingSong;
@@ -765,7 +765,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
else if( input.MenuI == m_GameButtonPreviousDifficulty )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
m_SelectionState = SelectionState_SelectingSong;
@@ -776,7 +776,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
else if( input.MenuI == m_GameButtonNextDifficulty )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
m_SelectionState = SelectionState_SelectingSong;
@@ -788,7 +788,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
else if(input.MenuI == m_GameButtonPreviousGroup )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
RString sNewGroup = m_MusicWheel.JumpToPrevGroup();
@@ -802,7 +802,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
else if(input.MenuI == m_GameButtonNextGroup )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
RString sNewGroup = m_MusicWheel.JumpToNextGroup();
@@ -824,14 +824,14 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
if( input.MenuI == m_GameButtonPreviousSong )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
ChangeSteps( input.pn, -1 );
}
else if( input.MenuI == m_GameButtonNextSong )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
ChangeSteps( input.pn, +1 );
}
@@ -839,7 +839,7 @@ bool ScreenSelectMusic::Input( const InputEventPlus &input )
else if( input.MenuI == GAME_BUTTON_MENUUP || input.MenuI == GAME_BUTTON_MENUDOWN ) // && TWO_PART_DESELECTS_WITH_MENUUPDOWN
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
// XXX: should this be called "TwoPartCancelled"?
@@ -869,14 +869,14 @@ bool ScreenSelectMusic::DetectCodes( const InputEventPlus &input )
if( CodeDetector::EnteredPrevSteps(input.GameI.controller) && !CHANGE_STEPS_WITH_GAME_BUTTONS )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
ChangeSteps( input.pn, -1 );
}
else if( CodeDetector::EnteredNextSteps(input.GameI.controller) && !CHANGE_STEPS_WITH_GAME_BUTTONS )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
ChangeSteps( input.pn, +1 );
}
@@ -885,19 +885,19 @@ bool ScreenSelectMusic::DetectCodes( const InputEventPlus &input )
if( MODE_MENU_AVAILABLE )
m_MusicWheel.ChangeSort( SORT_MODE_MENU );
else
m_soundLocked.Play();
m_soundLocked.Play(true);
}
else if( CodeDetector::EnteredNextSort(input.GameI.controller) )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else if( !GAMESTATE->IsCourseMode() )
// Only change sorts in non-course mode
m_MusicWheel.NextSort();
}
else if( !GAMESTATE->IsAnExtraStageAndSelectionLocked() && CodeDetector::DetectAndAdjustMusicOptions(input.GameI.controller) )
{
m_soundOptionsChange.Play();
m_soundOptionsChange.Play(true);
Message msg( "PlayerOptionsChanged" );
msg.SetParam( "PlayerNumber", input.pn );
@@ -908,7 +908,7 @@ bool ScreenSelectMusic::DetectCodes( const InputEventPlus &input )
else if( CodeDetector::EnteredNextGroup(input.GameI.controller) && !CHANGE_GROUPS_WITH_GAME_BUTTONS )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
RString sNewGroup = m_MusicWheel.JumpToNextGroup();
@@ -921,7 +921,7 @@ bool ScreenSelectMusic::DetectCodes( const InputEventPlus &input )
else if( CodeDetector::EnteredPrevGroup(input.GameI.controller) && !CHANGE_GROUPS_WITH_GAME_BUTTONS )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
RString sNewGroup = m_MusicWheel.JumpToPrevGroup();
@@ -934,7 +934,7 @@ bool ScreenSelectMusic::DetectCodes( const InputEventPlus &input )
else if( CodeDetector::EnteredCloseFolder(input.GameI.controller) )
{
if( GAMESTATE->IsAnExtraStageAndSelectionLocked() )
m_soundLocked.Play();
m_soundLocked.Play(true);
else
{
RString sCurSection = m_MusicWheel.GetSelectedSection();
@@ -1377,7 +1377,7 @@ bool ScreenSelectMusic::MenuStart( const InputEventPlus &input )
if( !bAllPlayersDoneSelectingSteps )
{
m_bStepsChosen[pn] = true;
m_soundStart.Play();
m_soundStart.Play(true);
// impldiff: Pump it Up Pro uses "StepsSelected". -aj
Message msg("StepsChosen");
@@ -1403,7 +1403,7 @@ bool ScreenSelectMusic::MenuStart( const InputEventPlus &input )
Message msg( "Start" + SelectionStateToString(m_SelectionState) );
MESSAGEMAN->Broadcast( msg );
m_soundStart.Play();
m_soundStart.Play(true);
// If the MenuTimer has forced us to move on && TWO_PART_CONFIRMS_ONLY,
// set Selection State to finalized and move on.
@@ -1425,7 +1425,7 @@ bool ScreenSelectMusic::MenuStart( const InputEventPlus &input )
{
m_bStepsChosen[p] = true;
// Don't play start sound. We play it again below on finalized
//m_soundStart.Play();
//m_soundStart.Play(true);
Message lMsg("StepsChosen");
lMsg.SetParam( "Player", p );
+2 -2
View File
@@ -137,7 +137,7 @@ void ScreenSetTime::ChangeValue( int iDirection )
m_TimeOffset = iAdjusted - iNow;
m_soundChangeValue.Play();
m_soundChangeValue.Play(true);
}
void ScreenSetTime::ChangeSelection( int iDirection )
@@ -156,7 +156,7 @@ void ScreenSetTime::ChangeSelection( int iDirection )
RageColor(1,1,1,1) );
if( iDirection != 0 )
m_soundChangeSelection.Play();
m_soundChangeSelection.Play(true);
}
bool ScreenSetTime::MenuUp( const InputEventPlus &input )
+2 -2
View File
@@ -57,7 +57,7 @@ void ScreenTestSound::Init()
s[i].s.SetParams( p );
//s[0].s.SetStopMode(RageSound::M_LOOP);
//s[0].s.Play();
//s[0].s.Play(false);
selected = 0;
for( int i = 0; i < nsounds; ++i )
@@ -149,7 +149,7 @@ bool ScreenTestSound::Input( const InputEventPlus &input )
* and we won't be allowed to touch it. Copy it ourself. */
RageSound *pCopy = new RageSound( s[selected].s );
m_sSoundCopies[selected].push_back( pCopy );
pCopy->Play();
pCopy->Play(false);
break;
}
case 's':
+4 -4
View File
@@ -278,7 +278,7 @@ void ScreenTextEntry::TryAppendToAnswer( RString s )
wstring sNewAnswer = m_sAnswer+RStringToWstring(s);
m_sAnswer = sNewAnswer;
m_sndType.Play();
m_sndType.Play(true);
UpdateAnswerText();
}
@@ -290,7 +290,7 @@ void ScreenTextEntry::BackspaceInAnswer()
return;
}
m_sAnswer.erase( m_sAnswer.end()-1 );
m_sndBackspace.Play();
m_sndBackspace.Play(true);
UpdateAnswerText();
}
@@ -703,7 +703,7 @@ void ScreenTextEntryVisual::MoveX( int iDir )
}
while( sKey == "" );
m_sndChange.Play();
m_sndChange.Play(true);
PositionCursor();
}
@@ -735,7 +735,7 @@ void ScreenTextEntryVisual::MoveY( int iDir )
}
while( sKey == "" );
m_sndChange.Play();
m_sndChange.Play(true);
PositionCursor();
}
+1 -1
View File
@@ -48,7 +48,7 @@ void ScreenUnlockBrowse::BeginScreen()
bool ScreenUnlockBrowse::MenuStart( const InputEventPlus &input )
{
m_soundStart.Play();
m_soundStart.Play(true);
this->PostScreenMessage( SM_BeginFadingOut, 0 );
return true;
}
+7 -7
View File
@@ -233,14 +233,14 @@ void WheelBase::Update( float fDeltaTime )
ChangeMusic( m_Moving );
if( PREFSMAN->m_iMusicWheelSwitchSpeed < MAX_WHEEL_SOUND_SPEED )
m_soundChangeMusic.Play();
m_soundChangeMusic.Play(true);
}
if( PREFSMAN->m_iMusicWheelSwitchSpeed >= MAX_WHEEL_SOUND_SPEED &&
m_MovingSoundTimer.PeekDeltaTime() >= 1.0f / MAX_WHEEL_SOUND_SPEED )
{
m_MovingSoundTimer.GetDeltaTime();
m_soundChangeMusic.Play();
m_soundChangeMusic.Play(true);
}
}
else
@@ -297,12 +297,12 @@ bool WheelBase::Select() // return true if this selection can end the screen
if( m_sExpandedSectionName == sThisItemSectionName ) // already expanded
{
SetOpenSection( "" ); // collapse it
m_soundCollapse.Play();
m_soundCollapse.Play(true);
}
else // already collapsed
{
SetOpenSection( sThisItemSectionName ); // expand it
m_soundExpand.Play();
m_soundExpand.Play(true);
}
}
// Opening/closing sections cannot end the screen
@@ -357,7 +357,7 @@ void WheelBase::ChangeMusicUnlessLocked( int n )
{
int iSign = n/abs(n);
m_fLockedWheelVelocity = iSign*LOCKED_INITIAL_VELOCITY;
m_soundLocked.Play();
m_soundLocked.Play(true);
}
return;
}
@@ -376,7 +376,7 @@ void WheelBase::Move(int n)
{
int iSign = n/abs(n);
m_fLockedWheelVelocity = iSign*LOCKED_INITIAL_VELOCITY;
m_soundLocked.Play();
m_soundLocked.Play(true);
}
return;
}
@@ -441,7 +441,7 @@ void WheelBase::ChangeMusic( int iDist )
/* If we're moving automatically, don't play this; it'll be called in Update. */
if(!IsMoving())
m_soundChangeMusic.Play();
m_soundChangeMusic.Play(true);
}
void WheelBase::RebuildWheelItems( int iDist )