Init()
This commit is contained in:
@@ -37,6 +37,11 @@ REGISTER_SCREEN_CLASS( ScreenDemonstration );
|
|||||||
ScreenDemonstration::ScreenDemonstration( CString sName ) : ScreenJukebox( sName, PrepareForDemonstration() ) // this is a hack to get some code to execute before the ScreenGameplay constructor
|
ScreenDemonstration::ScreenDemonstration( CString sName ) : ScreenJukebox( sName, PrepareForDemonstration() ) // this is a hack to get some code to execute before the ScreenGameplay constructor
|
||||||
{
|
{
|
||||||
LOG->Trace( "ScreenDemonstration::ScreenDemonstration()" );
|
LOG->Trace( "ScreenDemonstration::ScreenDemonstration()" );
|
||||||
|
}
|
||||||
|
|
||||||
|
void ScreenDemonstration::Init()
|
||||||
|
{
|
||||||
|
ScreenJukebox::Init();
|
||||||
|
|
||||||
if( GAMESTATE->m_pCurSong == NULL ) // we didn't find a song.
|
if( GAMESTATE->m_pCurSong == NULL ) // we didn't find a song.
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ class ScreenDemonstration : public ScreenJukebox
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
ScreenDemonstration( CString sName );
|
ScreenDemonstration( CString sName );
|
||||||
|
virtual void Init();
|
||||||
|
|
||||||
virtual void HandleScreenMessage( const ScreenMessage SM );
|
virtual void HandleScreenMessage( const ScreenMessage SM );
|
||||||
|
|
||||||
|
|||||||
@@ -88,12 +88,12 @@ REGISTER_SCREEN_CLASS( ScreenEvaluation );
|
|||||||
ScreenEvaluation::ScreenEvaluation( CString sClassName ) : ScreenWithMenuElements(sClassName)
|
ScreenEvaluation::ScreenEvaluation( CString sClassName ) : ScreenWithMenuElements(sClassName)
|
||||||
{
|
{
|
||||||
LOG->Trace( "ScreenEvaluation::ScreenEvaluation" );
|
LOG->Trace( "ScreenEvaluation::ScreenEvaluation" );
|
||||||
Init(); // work around horrible gcc bug 3187
|
|
||||||
LOG->Trace( "exiting ScreenEvaluation::ScreenEvalaution" );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScreenEvaluation::Init()
|
void ScreenEvaluation::Init()
|
||||||
{
|
{
|
||||||
|
Screen::Init();
|
||||||
|
|
||||||
//
|
//
|
||||||
// debugging
|
// debugging
|
||||||
//
|
//
|
||||||
|
|||||||
@@ -50,7 +50,7 @@ public:
|
|||||||
virtual void MenuStart( PlayerNumber pn );
|
virtual void MenuStart( PlayerNumber pn );
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void Init();
|
virtual void Init();
|
||||||
void CommitScores(
|
void CommitScores(
|
||||||
const StageStats &stageStats,
|
const StageStats &stageStats,
|
||||||
int iPersonalHighScoreIndexOut[NUM_PLAYERS],
|
int iPersonalHighScoreIndexOut[NUM_PLAYERS],
|
||||||
|
|||||||
@@ -89,11 +89,12 @@ REGISTER_SCREEN_CLASS( ScreenGameplay );
|
|||||||
ScreenGameplay::ScreenGameplay( CString sName, bool bDemonstration ) : Screen(sName)
|
ScreenGameplay::ScreenGameplay( CString sName, bool bDemonstration ) : Screen(sName)
|
||||||
{
|
{
|
||||||
m_bDemonstration = bDemonstration;
|
m_bDemonstration = bDemonstration;
|
||||||
Init(); // work around horrible gcc bug 3187
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScreenGameplay::Init()
|
void ScreenGameplay::Init()
|
||||||
{
|
{
|
||||||
|
Screen::Init();
|
||||||
|
|
||||||
if( m_bDemonstration )
|
if( m_bDemonstration )
|
||||||
LIGHTSMAN->SetLightsMode( LIGHTSMODE_DEMONSTRATION );
|
LIGHTSMAN->SetLightsMode( LIGHTSMODE_DEMONSTRATION );
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -56,7 +56,7 @@ class ScreenGameplay : public Screen
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
ScreenGameplay( CString sName, bool bDemonstration = false );
|
ScreenGameplay( CString sName, bool bDemonstration = false );
|
||||||
void Init();
|
virtual void Init();
|
||||||
virtual ~ScreenGameplay();
|
virtual ~ScreenGameplay();
|
||||||
|
|
||||||
virtual void Update( float fDeltaTime );
|
virtual void Update( float fDeltaTime );
|
||||||
|
|||||||
@@ -39,11 +39,12 @@ const ScreenMessage SM_GoToScreenAfterBack = ScreenMessage(SM_User+23);
|
|||||||
REGISTER_SCREEN_CLASS( ScreenGameplayMultiplayer );
|
REGISTER_SCREEN_CLASS( ScreenGameplayMultiplayer );
|
||||||
ScreenGameplayMultiplayer::ScreenGameplayMultiplayer( CString sName, bool bDemonstration ) : Screen(sName)
|
ScreenGameplayMultiplayer::ScreenGameplayMultiplayer( CString sName, bool bDemonstration ) : Screen(sName)
|
||||||
{
|
{
|
||||||
Init(); // work around horrible gcc bug 3187
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScreenGameplayMultiplayer::Init()
|
void ScreenGameplayMultiplayer::Init()
|
||||||
{
|
{
|
||||||
|
Screen::Init();
|
||||||
|
|
||||||
m_pSoundMusic = NULL;
|
m_pSoundMusic = NULL;
|
||||||
|
|
||||||
/* We do this ourself. */
|
/* We do this ourself. */
|
||||||
|
|||||||
@@ -167,6 +167,11 @@ bool ScreenJukebox::PrepareForJukebox( bool bDemonstration ) // always return t
|
|||||||
ScreenJukebox::ScreenJukebox( CString sName, bool bDemonstration ) : ScreenGameplay( "ScreenGameplay", PrepareForJukebox(bDemonstration) ) // this is a hack to get some code to execute before the ScreenGameplay constructor
|
ScreenJukebox::ScreenJukebox( CString sName, bool bDemonstration ) : ScreenGameplay( "ScreenGameplay", PrepareForJukebox(bDemonstration) ) // this is a hack to get some code to execute before the ScreenGameplay constructor
|
||||||
{
|
{
|
||||||
LOG->Trace( "ScreenJukebox::ScreenJukebox()" );
|
LOG->Trace( "ScreenJukebox::ScreenJukebox()" );
|
||||||
|
}
|
||||||
|
|
||||||
|
void ScreenJukebox::Init()
|
||||||
|
{
|
||||||
|
ScreenGameplay::Init();
|
||||||
|
|
||||||
if( GAMESTATE->m_pCurSong == NULL ) // we didn't find a song.
|
if( GAMESTATE->m_pCurSong == NULL ) // we didn't find a song.
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -11,6 +11,7 @@ class ScreenJukebox : public ScreenGameplay
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
ScreenJukebox( CString sName, bool bDemonstration = false );
|
ScreenJukebox( CString sName, bool bDemonstration = false );
|
||||||
|
virtual void Init();
|
||||||
|
|
||||||
virtual void Input( const DeviceInput& DeviceI, const InputEventType type, const GameInput &GameI, const MenuInput &MenuI, const StyleInput &StyleI );
|
virtual void Input( const DeviceInput& DeviceI, const InputEventType type, const GameInput &GameI, const MenuInput &MenuI, const StyleInput &StyleI );
|
||||||
virtual void HandleScreenMessage( const ScreenMessage SM );
|
virtual void HandleScreenMessage( const ScreenMessage SM );
|
||||||
|
|||||||
Reference in New Issue
Block a user