m_Overlay -> m_sprOverlay, to be consistent with SWME

remove character stuff that can be done with the overlay
This commit is contained in:
Glenn Maynard
2005-06-19 22:48:58 +00:00
parent f98f8794ce
commit 25531ef460
2 changed files with 7 additions and 32 deletions
+6 -25
View File
@@ -2,18 +2,14 @@
#include "ActorUtil.h"
#include "ScreenStage.h"
#include "ScreenManager.h"
#include "PrefsManager.h"
#include "RageLog.h"
#include "GameConstantsAndTypes.h"
#include "BitmapText.h"
#include "SongManager.h"
#include "Sprite.h"
#include "AnnouncerManager.h"
#include "GameState.h"
#include "GameSoundManager.h"
#include "ThemeManager.h"
#include "LightsManager.h"
#include "song.h"
#define NEXT_SCREEN THEME->GetMetric (m_sName,"NextScreen")
#define PREV_SCREEN THEME->GetMetric (m_sName,"PrevScreen")
@@ -38,10 +34,11 @@ void ScreenStage::Init()
LIGHTSMAN->SetLightsMode( LIGHTSMODE_STAGE );
m_Overlay.Load( THEME->GetPathB(m_sName,"overlay") );
m_Overlay->SetName( "Overlay" );
ON_COMMAND( m_Overlay );
this->AddChild( m_Overlay );
m_sprOverlay.Load( THEME->GetPathB(m_sName,"overlay") );
m_sprOverlay->SetName( "Overlay" );
m_sprOverlay->SetDrawOrder( DRAW_ORDER_OVERLAY );
ON_COMMAND( m_sprOverlay );
this->AddChild( m_sprOverlay );
m_In.Load( THEME->GetPathB(m_sName,"in") );
m_In.StartTransitioning();
@@ -57,21 +54,7 @@ void ScreenStage::Init()
this->AddChild( &m_Cancel );
/* Prep the new screen once m_In is complete. */
this->PostScreenMessage( SM_PrepScreen, m_Overlay->GetTweenTimeLeft() );
FOREACH_PlayerNumber(p)
{
m_sprCharacterIcon[p].SetName( ssprintf("CharacterIconP%d",p+1) );
const Character *pChar = GAMESTATE->m_pCurCharacters[p];
CString sPath = pChar->GetStageIconPath();
if( sPath == "" )
continue;
m_sprCharacterIcon[p].Load( pChar->GetStageIconPath() );
SET_XY_AND_ON_COMMAND( m_sprCharacterIcon[p] );
this->AddChild( &m_sprCharacterIcon[p] );
}
this->PostScreenMessage( SM_PrepScreen, m_sprOverlay->GetTweenTimeLeft() );
SOUND->PlayOnceFromDir( ANNOUNCER->GetPathTo("stage "+StageToString(GAMESTATE->GetCurrentStage())) );
@@ -93,8 +76,6 @@ void ScreenStage::HandleScreenMessage( const ScreenMessage SM )
else if( SM == SM_BeginFadingOut )
{
m_Out.StartTransitioning();
FOREACH_PlayerNumber( p )
OFF_COMMAND( m_sprCharacterIcon[p] );
this->PostScreenMessage( SM_GoToNextScreen, this->GetTweenTimeLeft() );
}
else if( SM == SM_GoToNextScreen )
+1 -7
View File
@@ -5,9 +5,6 @@
#include "Screen.h"
#include "Transition.h"
#include "Sprite.h"
#include "Character.h"
#include "BitmapText.h"
#include "ActorUtil.h"
#include "ThemeMetric.h"
@@ -25,10 +22,7 @@ private:
ThemeMetric<bool> ALLOW_BACK;
Transition m_In, m_Out, m_Cancel;
AutoActor m_Overlay; // overlays all elements except bitmaptexts
// elements that cannot be created with BGAnimation
Sprite m_sprCharacterIcon[NUM_PLAYERS];
AutoActor m_sprOverlay;
bool m_bZeroDeltaOnNextUpdate;
};