m_vpBGAnimations hasn't actually done anything in about a year (it's
never loaded); remove it. It's not useful, anyway: it gives no means to tween options when changing the selection.
This commit is contained in:
@@ -53,12 +53,6 @@ ScreenSelect::ScreenSelect( CString sClassName ) :
|
|||||||
mc.m_sName = sChoiceName;
|
mc.m_sName = sChoiceName;
|
||||||
mc.Load( c, CHOICE(sChoiceName) );
|
mc.Load( c, CHOICE(sChoiceName) );
|
||||||
m_aGameCommands.push_back( mc );
|
m_aGameCommands.push_back( mc );
|
||||||
|
|
||||||
CString sBGAnimationDir = THEME->GetPath(BGAnimations, m_sName, mc.m_sName, true); // true="optional"
|
|
||||||
if( sBGAnimationDir == "" )
|
|
||||||
sBGAnimationDir = THEME->GetPathToB(m_sName+" background");
|
|
||||||
BGAnimation *pBGA = new BGAnimation;
|
|
||||||
m_vpBGAnimations.push_back( pBGA );
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -95,9 +89,6 @@ ScreenSelect::ScreenSelect( CString sClassName ) :
|
|||||||
ScreenSelect::~ScreenSelect()
|
ScreenSelect::~ScreenSelect()
|
||||||
{
|
{
|
||||||
LOG->Trace( "ScreenSelect::~ScreenSelect()" );
|
LOG->Trace( "ScreenSelect::~ScreenSelect()" );
|
||||||
for( unsigned i=0; i<m_vpBGAnimations.size(); i++ )
|
|
||||||
SAFE_DELETE( m_vpBGAnimations[i] );
|
|
||||||
m_vpBGAnimations.clear();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScreenSelect::Update( float fDelta )
|
void ScreenSelect::Update( float fDelta )
|
||||||
@@ -130,25 +121,10 @@ void ScreenSelect::Update( float fDelta )
|
|||||||
}
|
}
|
||||||
|
|
||||||
Screen::Update( fDelta );
|
Screen::Update( fDelta );
|
||||||
|
|
||||||
// GAMESTATE->m_MasterPlayerNumber is set to PLAYER_INVALID when going Back to
|
|
||||||
// the title screen and this screen is updated after. TODO: find out why
|
|
||||||
if( GAMESTATE->m_MasterPlayerNumber != PLAYER_INVALID )
|
|
||||||
{
|
|
||||||
int iSelection = this->GetSelectionIndex(GAMESTATE->m_MasterPlayerNumber);
|
|
||||||
m_vpBGAnimations[iSelection]->Update( fDelta );
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScreenSelect::DrawPrimitives()
|
void ScreenSelect::DrawPrimitives()
|
||||||
{
|
{
|
||||||
// GAMESTATE->m_MasterPlayerNumber is set to PLAYER_INVALID when going Back to
|
|
||||||
// the title screen and this screen is updated after. TODO: find out why
|
|
||||||
if( GAMESTATE->m_MasterPlayerNumber != PLAYER_INVALID )
|
|
||||||
{
|
|
||||||
int iSelection = this->GetSelectionIndex(GAMESTATE->m_MasterPlayerNumber);
|
|
||||||
m_vpBGAnimations[iSelection]->Draw();
|
|
||||||
}
|
|
||||||
Screen::DrawPrimitives();
|
Screen::DrawPrimitives();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,6 @@
|
|||||||
#define SCREEN_SELECT_H
|
#define SCREEN_SELECT_H
|
||||||
|
|
||||||
#include "ScreenWithMenuElements.h"
|
#include "ScreenWithMenuElements.h"
|
||||||
#include "BGAnimation.h"
|
|
||||||
#include "GameCommand.h"
|
#include "GameCommand.h"
|
||||||
#include "CodeDetector.h"
|
#include "CodeDetector.h"
|
||||||
#include "ThemeMetric.h"
|
#include "ThemeMetric.h"
|
||||||
@@ -29,7 +28,6 @@ protected:
|
|||||||
virtual int GetSelectionIndex( PlayerNumber pn ) = 0;
|
virtual int GetSelectionIndex( PlayerNumber pn ) = 0;
|
||||||
virtual void UpdateSelectableChoices() = 0; // derived screens must handle this
|
virtual void UpdateSelectableChoices() = 0; // derived screens must handle this
|
||||||
|
|
||||||
vector<BGAnimation*> m_vpBGAnimations;
|
|
||||||
vector<GameCommand> m_aGameCommands; // derived classes should look here for what choices are available
|
vector<GameCommand> m_aGameCommands; // derived classes should look here for what choices are available
|
||||||
|
|
||||||
vector<CodeItem> m_aCodes;
|
vector<CodeItem> m_aCodes;
|
||||||
|
|||||||
Reference in New Issue
Block a user