diff --git a/stepmania/src/Makefile.am b/stepmania/src/Makefile.am index c2941ea7af..a621935a94 100644 --- a/stepmania/src/Makefile.am +++ b/stepmania/src/Makefile.am @@ -22,7 +22,7 @@ $(srcdir)/libresample/libresample.a: Screens = \ Screen.cpp Screen.h ScreenAttract.cpp ScreenAttract.h \ -ScreenBookkeeping.cpp ScreenBookkeeping.h ScreenBranch.cpp ScreenBranch.h ScreenCaution.cpp ScreenCaution.h \ +ScreenBookkeeping.cpp ScreenBookkeeping.h ScreenBranch.cpp ScreenBranch.h \ ScreenCenterImage.cpp ScreenCenterImage.h ScreenCredits.cpp ScreenCredits.h \ ScreenDemonstration.cpp ScreenDemonstration.h ScreenDimensions.h \ ScreenClearBookkeepingData.cpp ScreenClearBookkeepingData.h ScreenClearMachineStats.cpp ScreenClearMachineStats.h \ diff --git a/stepmania/src/ScreenCaution.cpp b/stepmania/src/ScreenCaution.cpp deleted file mode 100644 index dd1e41af68..0000000000 --- a/stepmania/src/ScreenCaution.cpp +++ /dev/null @@ -1,116 +0,0 @@ -#include "global.h" -#include "ScreenCaution.h" -#include "GameConstantsAndTypes.h" -#include "PrefsManager.h" -#include "ScreenManager.h" -#include "AnnouncerManager.h" -#include "GameSoundManager.h" -#include "ThemeManager.h" - -#define NEXT_SCREEN THEME->GetMetric(m_sName,"NextScreen") - - -const ScreenMessage SM_DoneOpening = ScreenMessage(SM_User-7); -const ScreenMessage SM_StartClosing = ScreenMessage(SM_User-8); - - -REGISTER_SCREEN_CLASS( ScreenCaution ); -ScreenCaution::ScreenCaution( CString sName ) : Screen( sName ) -{ - if(!PREFSMAN->m_bShowCaution) - { - this->PostScreenMessage( SM_GoToNextScreen, 0.f ); - return; - } - - m_Background.LoadFromAniDir( THEME->GetPathB(m_sName,"background") ); - this->AddChild( &m_Background ); - - m_In.Load( THEME->GetPathB(m_sName,"in") ); - m_In.StartTransitioning( SM_DoneOpening ); - this->AddChild( &m_In ); - - m_Out.Load( THEME->GetPathB(m_sName,"out") ); - this->AddChild( &m_Out ); - - m_Back.Load( THEME->GetPathToB("Common back") ); - this->AddChild( &m_Back ); - - float fCloseInSeconds = m_Background.GetLengthSeconds()-m_Out.GetLengthSeconds(); - fCloseInSeconds = max( 0, fCloseInSeconds ); - this->PostScreenMessage( SM_StartClosing, fCloseInSeconds ); - - SOUND->PlayMusic( THEME->GetPathS(m_sName,"music") ); -} - - -void ScreenCaution::Input( const DeviceInput& DeviceI, const InputEventType type, const GameInput &GameI, const MenuInput &MenuI, const StyleInput &StyleI ) -{ - if( Screen::JoinInput( DeviceI, type, GameI, MenuI, StyleI ) ) - return; // handled - - Screen::Input( DeviceI, type, GameI, MenuI, StyleI ); -} - - -void ScreenCaution::HandleScreenMessage( const ScreenMessage SM ) -{ - switch( SM ) - { - case SM_StartClosing: - m_Background.PlayCommand("Off"); - m_Out.StartTransitioning( SM_GoToNextScreen ); - break; - case SM_DoneOpening: - SOUND->PlayOnceFromDir( ANNOUNCER->GetPathTo("caution") ); - break; - case SM_GoToPrevScreen: - SCREENMAN->SetNewScreen( "ScreenTitleMenu" ); - break; - case SM_GoToNextScreen: - SCREENMAN->SetNewScreen( NEXT_SCREEN ); - break; - } -} - -void ScreenCaution::MenuStart( PlayerNumber pn ) -{ - if( m_In.IsTransitioning() || m_Out.IsTransitioning() || m_Back.IsTransitioning() ) - return; - m_Background.PlayCommand("Off"); - m_Out.StartTransitioning( SM_GoToNextScreen ); -} - -void ScreenCaution::MenuBack( PlayerNumber pn ) -{ - if( m_In.IsTransitioning() || m_Out.IsTransitioning() || m_Back.IsTransitioning() ) - return; - this->ClearMessageQueue(); - m_Back.StartTransitioning( SM_GoToPrevScreen ); - SCREENMAN->PlayBackSound(); -} - -/* - * (c) 2001-2004 Chris Danford - * All rights reserved. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the - * "Software"), to deal in the Software without restriction, including - * without limitation the rights to use, copy, modify, merge, publish, - * distribute, and/or sell copies of the Software, and to permit persons to - * whom the Software is furnished to do so, provided that the above - * copyright notice(s) and this permission notice appear in all copies of - * the Software and that both the above copyright notice(s) and this - * permission notice appear in supporting documentation. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS - * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF - * THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS - * INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT - * OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS - * OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR - * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ diff --git a/stepmania/src/ScreenCaution.h b/stepmania/src/ScreenCaution.h deleted file mode 100644 index 512aaed9ea..0000000000 --- a/stepmania/src/ScreenCaution.h +++ /dev/null @@ -1,52 +0,0 @@ -#ifndef SCREEN_CAUTION_H -#define SCREEN_CAUTION_H - -#include "Screen.h" -#include "RandomSample.h" -#include "BGAnimation.h" -#include "Transition.h" - - -class ScreenCaution : public Screen -{ -public: - ScreenCaution( CString sName ); - - virtual void Input( const DeviceInput& DeviceI, const InputEventType type, const GameInput &GameI, const MenuInput &MenuI, const StyleInput &StyleI ); - virtual void HandleScreenMessage( const ScreenMessage SM ); - -protected: - void MenuStart( PlayerNumber pn ); - void MenuBack( PlayerNumber pn ); - BGAnimation m_Background; - Transition m_In; - Transition m_Out; - Transition m_Back; -}; - -#endif - -/* - * (c) 2001-2004 Chris Danford, Glenn Maynard - * All rights reserved. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the - * "Software"), to deal in the Software without restriction, including - * without limitation the rights to use, copy, modify, merge, publish, - * distribute, and/or sell copies of the Software, and to permit persons to - * whom the Software is furnished to do so, provided that the above - * copyright notice(s) and this permission notice appear in all copies of - * the Software and that both the above copyright notice(s) and this - * permission notice appear in supporting documentation. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS - * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF - * THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS - * INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT - * OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS - * OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR - * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ diff --git a/stepmania/src/StepMania.vcproj b/stepmania/src/StepMania.vcproj index d084a46dd0..cb118fa720 100644 --- a/stepmania/src/StepMania.vcproj +++ b/stepmania/src/StepMania.vcproj @@ -187,12 +187,6 @@ cl /Zl /nologo /c verstub.cpp /Fo"$(IntDir)"\ - - - -