From decdc6698cdf781e58cf765eb6e4e9f3c32d56a1 Mon Sep 17 00:00:00 2001 From: "born a rick, raised a morty, died a jerry" Date: Sun, 25 Nov 2018 02:33:35 -0500 Subject: [PATCH] this chartpreview music set is now handled by lua --- src/ScreenSelectMusic.cpp | 25 +------------------------ 1 file changed, 1 insertion(+), 24 deletions(-) diff --git a/src/ScreenSelectMusic.cpp b/src/ScreenSelectMusic.cpp index be4b180b91..a1902da0d6 100644 --- a/src/ScreenSelectMusic.cpp +++ b/src/ScreenSelectMusic.cpp @@ -1603,36 +1603,13 @@ ScreenSelectMusic::GeneratePreviewNoteField() GAMESTATE->m_bIsChartPreviewActive = true; - // Restart the music from the beginning for a full chart preview - - // (Enabling this would restart the music at its current position, but would - // never go back to earlier sections) - /* - m_fSampleStartSeconds = - SOUND->GetRageSoundPlaying()->GetPositionSeconds(); - */ - SOUND->StopMusic(); - m_sSampleMusicToPlay = song->GetMusicPath(); - m_fSampleStartSeconds = max(song->GetFirstSecond() - 4.f, -1.f); - m_fSampleLengthSeconds = - song->GetLastSecond() - m_fSampleStartSeconds + 2.f; - if (m_fSampleLengthSeconds < - 3.f) { // if the songpreview is after the last note - m_fSampleStartSeconds = - 5.f; // chartpreview wont play, just set it near the start -mina - m_fSampleLengthSeconds = song->GetLastSecond() + 2.f; - } - g_bSampleMusicWaiting = true; - CheckBackgroundRequests(true); - // Create and Render the NoteField afterwards // It is done in this order so we don't see it before the music changes. m_pPreviewNoteField = new NoteField; m_pPreviewNoteField->SetName( "NoteField"); // Use this to get the ActorFrame from the Screen Children - m_pPreviewNoteField->Init(GAMESTATE->m_pPlayerState[PLAYER_1], - 100); + m_pPreviewNoteField->Init(GAMESTATE->m_pPlayerState[PLAYER_1], 100); m_pPreviewNoteField->Load(&m_PreviewNoteData, 0, 800); }