From c6cfa14c1a2fba490b0726bbd36eb5bb24cc0a1c Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Sat, 24 Aug 2002 22:48:16 +0000 Subject: [PATCH] Don't render the beginning of the song when cancelling out of gameplay. --- stepmania/src/ScreenGameplay.cpp | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/stepmania/src/ScreenGameplay.cpp b/stepmania/src/ScreenGameplay.cpp index a0c86542dc..fae75b0c44 100644 --- a/stepmania/src/ScreenGameplay.cpp +++ b/stepmania/src/ScreenGameplay.cpp @@ -1019,7 +1019,24 @@ void ScreenGameplay::Input( const DeviceInput& DeviceI, const InputEventType typ { m_DancingState = STATE_OUTRO; SOUND->PlayOnceStreamed( THEME->GetPathTo("Sounds","menu back") ); - m_soundMusic.Stop(); + /* Hmm. There are a bunch of subtly different ways we can + * tween out: + * 1. Keep rendering the song, and keep it moving. This might + * cause problems if the cancel and the end of the song overlap. + * 2. Stop the song completely, so all song motion under the tween + * ceases. + * 3. Stop the song, but keep effects (eg. Drunk) running. + * 4. Don't display the song at all. + * + * We're doing #3. I'm not sure which is best. + * + * We have to pause the music, not stop it. If we stop it, + * its position will be 0, and we'll render the *start* + * of the song while we tween out, which looks really strange. + * -glenn + */ + m_soundMusic.Pause(); + this->ClearMessageQueue(); m_Fade.CloseWipingLeft( SM_SaveChangedBeforeGoingBack ); }