From 56cc2e3996f648083b97c6f212c9f01736ccd9d0 Mon Sep 17 00:00:00 2001 From: Mark Cannon Date: Thu, 26 Mar 2009 23:54:16 +0000 Subject: [PATCH] Fix minor lights flicker on ScreenStage -> ScreenGameplay, remove some unused debug code from RFDZip. git-svn-id: https://openitg.svn.sourceforge.net/svnroot/openitg@596 83fadc84-e282-4d84-a09a-c4228d6ae7e5 --- changelog.txt | 1 + src/RageFileDriverZip.cpp | 4 ---- src/ScreenGameplay.cpp | 21 +++++++++++---------- 3 files changed, 12 insertions(+), 14 deletions(-) diff --git a/changelog.txt b/changelog.txt index ed1f16cc..3db42214 100755 --- a/changelog.txt +++ b/changelog.txt @@ -45,6 +45,7 @@ OpenITG, beta 1 (almost done) Sensor reading problems with PIUIO Patched OGG songs circumvented Long/Marathon song limits No-timeout warning flood on custom song loading + Crash on Edit-only songs (not a bug, but...) -Misc. changes: Re-backported input debounce, except it works this time. :) Record service credits separately in MachineProfile and Coins.xml diff --git a/src/RageFileDriverZip.cpp b/src/RageFileDriverZip.cpp index 4b235c4d..ceb5df9f 100755 --- a/src/RageFileDriverZip.cpp +++ b/src/RageFileDriverZip.cpp @@ -101,8 +101,6 @@ bool RageFileDriverZip::SeekToEndCentralRecord() const int iSearchTo = max( m_pZip->GetFileSize() - 1024*32, 0 ); int iRealPos = m_pZip->GetFileSize(); - LOG->Info( "iRealPos: %i, iSearchTo: %i", iRealPos, iSearchTo ); - while( iRealPos > 0 && iRealPos >= iSearchTo ) { /* Move back in the file; leave some overlap between checks, to handle @@ -125,8 +123,6 @@ bool RageFileDriverZip::SeekToEndCentralRecord() if( memcmp(buf + iPos, "\x50\x4B\x05\x06", 4) ) continue; - LOG->Warn( "End-of-central directory found at %i", m_pZip->Tell() - iPos ); - m_pZip->Seek( iRealPos + iPos ); return true; } diff --git a/src/ScreenGameplay.cpp b/src/ScreenGameplay.cpp index 289e0ded..d5776154 100755 --- a/src/ScreenGameplay.cpp +++ b/src/ScreenGameplay.cpp @@ -1068,16 +1068,6 @@ void ScreenGameplay::LoadNextSong() m_bZeroDeltaOnNextUpdate = true; SCREENMAN->ZeroNextUpdate(); - // load the lights and manually update once, THEN set the state, - // so we avoid skipping between the state and transition here. - LoadLights(); - UpdateLights(); - - if( GAMESTATE->m_bDemonstrationOrJukebox ) - LIGHTSMAN->SetLightsMode( LIGHTSMODE_DEMONSTRATION ); - else - LIGHTSMAN->SetLightsMode( LIGHTSMODE_GAMEPLAY ); - /* Load the music last, since it may start streaming and we don't want the music * to compete with other loading. */ @@ -1370,6 +1360,17 @@ void ScreenGameplay::Update( float fDeltaTime ) if( m_bFirstUpdate ) { + // load the lights and manually update once, THEN set the state, + // so we avoid skipping between the state and transition here. + LoadLights(); + UpdateLights(); + + if( GAMESTATE->m_bDemonstrationOrJukebox ) + LIGHTSMAN->SetLightsMode( LIGHTSMODE_DEMONSTRATION ); + else + LIGHTSMAN->SetLightsMode( LIGHTSMODE_GAMEPLAY ); + + SOUND->PlayOnceFromAnnouncer( "gameplay intro" ); // crowd cheer // -- 2.11.0