From c8ad4ea322118ab6b05b548d6a0c92022145380d Mon Sep 17 00:00:00 2001 From: Charles Lohr Date: Wed, 26 Jan 2005 06:48:01 +0000 Subject: [PATCH] Fix: The system should allow for the user to not have to start immediately. --- stepmania/src/ScreenGameplay.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/stepmania/src/ScreenGameplay.cpp b/stepmania/src/ScreenGameplay.cpp index 4d317f043f..e8cdf26887 100644 --- a/stepmania/src/ScreenGameplay.cpp +++ b/stepmania/src/ScreenGameplay.cpp @@ -86,6 +86,7 @@ const ScreenMessage SM_GoToScreenAfterFail = ScreenMessage(SM_User+31); const ScreenMessage SM_StartHereWeGo = ScreenMessage(SM_User+40); const ScreenMessage SM_StopHereWeGo = ScreenMessage(SM_User+41); +static Preference g_fNetStartOffset( Options, "NetworkStartOffset", -3.0 ); REGISTER_SCREEN_CLASS( ScreenGameplay ); ScreenGameplay::ScreenGameplay( CString sName ) : Screen(sName) @@ -1257,13 +1258,15 @@ void ScreenGameplay::Update( float fDeltaTime ) StartPlayingSong( 0, 0 ); m_pSoundMusic->Stop(); + float startOffset = g_fNetStartOffset; + NSMAN->StartRequest(1); RageSoundParams p; p.AccurateSync = true; p.SetPlaybackRate( 1.0 ); //Force 1.0 playback speed p.StopMode = RageSoundParams::M_CONTINUE; - p.m_StartSecond = 0.0; + p.m_StartSecond = startOffset; m_pSoundMusic->Play( &p ); UpdateSongPosition(0);