From 215ce5ad216dfaea3731537f2f7be2d45b692075 Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Fri, 15 Apr 2005 08:05:10 +0000 Subject: [PATCH] StartTransitioningCommand --- stepmania/src/Transition.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/stepmania/src/Transition.cpp b/stepmania/src/Transition.cpp index 0da3539347..088d740f38 100644 --- a/stepmania/src/Transition.cpp +++ b/stepmania/src/Transition.cpp @@ -6,6 +6,15 @@ #include "RageFile.h" +/* + * XXX: We send OnCommand on load, then we send no updates until we get + * StartTransitioning. Historically, this was fine, but it's incorrect now + * that commands can have arbitrary side-effects. We should only send OnCommand + * when we get StartTransitioning, but we need to run it early to set m_fLengthSeconds. + * Eventually, phase out GetLengthSeconds (ScreenGameplay is somewhat tricky). For + * now, play a "StartTransitioning" command; put anything that has side-effects in + * there, instead. + */ Transition::Transition() { m_State = waiting; @@ -94,6 +103,7 @@ void Transition::StartTransitioning( ScreenMessage send_when_done ) { if( m_State != waiting ) return; // ignore + m_sprTransition->PlayCommand( "StartTransitioning" ); m_MessageToSendWhenDone = send_when_done; m_State = transitioning;