SetHibernate can be called after queuing tweens. GetLengthSeconds is hacky, and needs to be removed ...

This commit is contained in:
Glenn Maynard
2006-06-25 20:08:31 +00:00
parent 33d89da000
commit 7c3c56f2b9
+2 -2
View File
@@ -246,15 +246,15 @@ void ScreenWithMenuElements::StartTransitioningScreen( ScreenMessage smSendWhenD
TweenOffScreen(); TweenOffScreen();
} }
m_Out.StartTransitioning( smSendWhenDone );
if( WAIT_FOR_CHILDREN_BEFORE_TWEENING_OUT ) if( WAIT_FOR_CHILDREN_BEFORE_TWEENING_OUT )
{ {
// Time the transition so that it finishes exactly when all actors have // Time the transition so that it finishes exactly when all actors have
// finished tweening. // finished tweening.
float fSecondsUntilFinished = GetTweenTimeLeft(); float fSecondsUntilFinished = GetTweenTimeLeft();
float fSecondsUntilBeginOff = max( fSecondsUntilFinished - m_Out.GetLengthSeconds(), 0 ); float fSecondsUntilBeginOff = max( fSecondsUntilFinished - m_Out.GetTweenTimeLeft(), 0 );
m_Out.SetHibernate( fSecondsUntilBeginOff ); m_Out.SetHibernate( fSecondsUntilBeginOff );
} }
m_Out.StartTransitioning( smSendWhenDone );
} }
void ScreenWithMenuElements::TweenOffScreen() void ScreenWithMenuElements::TweenOffScreen()