2003-02-16 04:01:45 +00:00
|
|
|
#include "global.h"
|
2002-05-20 08:59:37 +00:00
|
|
|
/*
|
|
|
|
|
-----------------------------------------------------------------------------
|
2002-08-01 13:42:56 +00:00
|
|
|
Class: ScreenSelectGroup
|
2002-05-20 08:59:37 +00:00
|
|
|
|
|
|
|
|
Desc: See header.
|
|
|
|
|
|
|
|
|
|
Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved.
|
|
|
|
|
Chris Danford
|
|
|
|
|
-----------------------------------------------------------------------------
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#include "ScreenSelectGroup.h"
|
|
|
|
|
#include "ScreenManager.h"
|
|
|
|
|
#include "PrefsManager.h"
|
|
|
|
|
#include "GameManager.h"
|
|
|
|
|
#include "RageLog.h"
|
|
|
|
|
#include "GameConstantsAndTypes.h"
|
|
|
|
|
#include "SongManager.h"
|
|
|
|
|
#include "AnnouncerManager.h"
|
2002-07-23 01:41:40 +00:00
|
|
|
#include "GameState.h"
|
2003-01-02 07:54:28 +00:00
|
|
|
#include "RageSoundManager.h"
|
2002-11-11 04:53:31 +00:00
|
|
|
#include "ThemeManager.h"
|
|
|
|
|
#include <map>
|
2002-08-27 03:59:22 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
#define FRAME_X THEME->GetMetricF("ScreenSelectGroup","FrameX")
|
|
|
|
|
#define FRAME_Y THEME->GetMetricF("ScreenSelectGroup","FrameY")
|
|
|
|
|
#define BANNER_X THEME->GetMetricF("ScreenSelectGroup","BannerX")
|
|
|
|
|
#define BANNER_Y THEME->GetMetricF("ScreenSelectGroup","BannerY")
|
|
|
|
|
#define BANNER_WIDTH THEME->GetMetricF("ScreenSelectGroup","BannerWidth")
|
|
|
|
|
#define BANNER_HEIGHT THEME->GetMetricF("ScreenSelectGroup","BannerHeight")
|
|
|
|
|
#define NUMBER_X THEME->GetMetricF("ScreenSelectGroup","NumberX")
|
|
|
|
|
#define NUMBER_Y THEME->GetMetricF("ScreenSelectGroup","NumberY")
|
|
|
|
|
#define EXPLANATION_X THEME->GetMetricF("ScreenSelectGroup","ExplanationX")
|
|
|
|
|
#define EXPLANATION_Y THEME->GetMetricF("ScreenSelectGroup","ExplanationY")
|
|
|
|
|
#define CONTENTS_X THEME->GetMetricF("ScreenSelectGroup","ContentsX")
|
|
|
|
|
#define CONTENTS_Y THEME->GetMetricF("ScreenSelectGroup","ContentsY")
|
|
|
|
|
#define HELP_TEXT THEME->GetMetric("ScreenSelectGroup","HelpText")
|
|
|
|
|
#define TIMER_SECONDS THEME->GetMetricI("ScreenSelectGroup","TimerSeconds")
|
2002-08-28 22:42:40 +00:00
|
|
|
#define NEXT_SCREEN THEME->GetMetric("ScreenSelectGroup","NextScreen")
|
2002-05-20 08:59:37 +00:00
|
|
|
|
|
|
|
|
|
2002-08-13 23:26:46 +00:00
|
|
|
const ScreenMessage SM_StartFadingOut = ScreenMessage(SM_User + 3);
|
2002-05-20 08:59:37 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
ScreenSelectGroup::ScreenSelectGroup()
|
|
|
|
|
{
|
2002-07-12 19:35:19 +00:00
|
|
|
|
2002-07-31 19:40:40 +00:00
|
|
|
LOG->Trace( "ScreenSelectGroup::ScreenSelectGroup()" );
|
2002-07-12 19:35:19 +00:00
|
|
|
|
2002-12-15 10:25:20 +00:00
|
|
|
m_Menu.Load(
|
|
|
|
|
THEME->GetPathTo("BGAnimations","select group") ,
|
|
|
|
|
THEME->GetPathTo("Graphics","select group top edge"),
|
|
|
|
|
HELP_TEXT, true, true, TIMER_SECONDS
|
|
|
|
|
);
|
|
|
|
|
this->AddChild( &m_Menu );
|
|
|
|
|
|
|
|
|
|
if(!PREFSMAN->m_bShowSelectGroup)
|
|
|
|
|
{
|
|
|
|
|
GAMESTATE->m_sPreferredGroup = "ALL MUSIC";
|
|
|
|
|
m_Menu.ImmedOffScreenToMenu();
|
2003-01-21 23:04:56 +00:00
|
|
|
m_bChosen = true;
|
2002-12-15 10:25:20 +00:00
|
|
|
this->SendScreenMessage( SM_GoToNextScreen, 0.f );
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
2002-07-12 19:35:19 +00:00
|
|
|
|
2002-10-31 03:01:35 +00:00
|
|
|
unsigned i;
|
|
|
|
|
int j;
|
2002-07-12 19:35:19 +00:00
|
|
|
|
|
|
|
|
// The new process by which the group and song lists are formed
|
|
|
|
|
// is bizarre and complex but yields the end result that songs
|
|
|
|
|
// and groups that do not contain any steps for the current
|
|
|
|
|
// style (such as solo) are omitted. Bear with me!
|
|
|
|
|
// -- dro kulix
|
|
|
|
|
|
2002-08-18 23:20:18 +00:00
|
|
|
// Chris:
|
|
|
|
|
// This is excellent! I'm going to move the filtering of songs
|
|
|
|
|
// that can't be played by current style to be the first action.
|
|
|
|
|
// This will simply the code a bit, and fix a weird case that
|
|
|
|
|
// causes a crash when there are duplicate song names.
|
|
|
|
|
|
2003-02-03 05:53:59 +00:00
|
|
|
vector<Song*> aAllSongs;
|
2003-02-10 05:30:12 +00:00
|
|
|
SONGMAN->GetSongs( aAllSongs );
|
2002-07-12 19:35:19 +00:00
|
|
|
|
2002-08-18 23:20:18 +00:00
|
|
|
// Filter out Songs that can't be played by the current Style
|
2002-10-31 03:01:35 +00:00
|
|
|
for( j=aAllSongs.size()-1; j>=0; j-- ) // foreach Song, back to front
|
2002-08-18 23:20:18 +00:00
|
|
|
{
|
2002-10-31 03:01:35 +00:00
|
|
|
if( aAllSongs[j]->SongCompleteForStyle(GAMESTATE->GetCurrentStyleDef()) &&
|
|
|
|
|
aAllSongs[j]->NormallyDisplayed() )
|
2002-09-06 08:56:28 +00:00
|
|
|
continue;
|
|
|
|
|
|
2002-10-31 04:11:08 +00:00
|
|
|
aAllSongs.erase( aAllSongs.begin()+j, aAllSongs.begin()+j+1 );
|
2002-08-18 23:20:18 +00:00
|
|
|
}
|
2002-07-12 19:35:19 +00:00
|
|
|
|
2002-11-11 04:53:31 +00:00
|
|
|
// Add all group names to a map.
|
|
|
|
|
std::map<CString, CString> mapGroupNames;
|
|
|
|
|
for( i=0; i<aAllSongs.size(); i++ )
|
|
|
|
|
{
|
|
|
|
|
const CString& sGroupName = aAllSongs[i]->m_sGroupName;
|
|
|
|
|
mapGroupNames[ sGroupName ] = ""; // group name maps to nothing
|
2002-09-07 06:46:18 +00:00
|
|
|
}
|
|
|
|
|
|
2002-11-11 04:53:31 +00:00
|
|
|
// copy group names into a vector
|
|
|
|
|
std::vector<CString> asGroupNames;
|
|
|
|
|
asGroupNames.push_back( "ALL MUSIC" ); // "ALL MUSIC" is a special group
|
2002-11-11 19:02:33 +00:00
|
|
|
for( std::map<CString, CString>::const_iterator iter = mapGroupNames.begin(); iter != mapGroupNames.end(); ++iter )
|
|
|
|
|
asGroupNames.push_back( iter->first );
|
2002-07-12 19:35:19 +00:00
|
|
|
|
2002-08-24 06:30:32 +00:00
|
|
|
// Add songs to the MusicList.
|
2002-10-31 04:36:35 +00:00
|
|
|
for( unsigned g=0; g < asGroupNames.size(); g++ ) /* for each group */
|
2002-08-18 23:20:18 +00:00
|
|
|
{
|
2003-01-03 05:56:28 +00:00
|
|
|
vector<Song*> aSongsInGroup;
|
2002-08-24 06:30:32 +00:00
|
|
|
/* find all songs */
|
2002-10-31 03:01:35 +00:00
|
|
|
for( i=0; i<aAllSongs.size(); i++ ) // foreach Song
|
2002-07-12 19:35:19 +00:00
|
|
|
{
|
2002-08-24 20:36:29 +00:00
|
|
|
/* group 0 gets all songs */
|
2002-10-31 04:36:35 +00:00
|
|
|
if( g != 0 && aAllSongs[i]->m_sGroupName != asGroupNames[g] )
|
2002-08-24 06:30:32 +00:00
|
|
|
continue;
|
|
|
|
|
|
2002-10-31 04:23:39 +00:00
|
|
|
aSongsInGroup.push_back( aAllSongs[i] );
|
2002-08-18 23:20:18 +00:00
|
|
|
}
|
2002-07-12 19:35:19 +00:00
|
|
|
|
2002-08-24 06:30:32 +00:00
|
|
|
SortSongPointerArrayByTitle( aSongsInGroup );
|
2002-07-12 19:35:19 +00:00
|
|
|
|
2002-08-24 06:30:32 +00:00
|
|
|
m_MusicList.AddGroup();
|
|
|
|
|
m_MusicList.AddSongsToGroup(aSongsInGroup);
|
|
|
|
|
}
|
2002-07-12 19:35:19 +00:00
|
|
|
|
2002-05-20 08:59:37 +00:00
|
|
|
m_bChosen = false;
|
|
|
|
|
|
2002-08-13 23:26:46 +00:00
|
|
|
m_sprExplanation.Load( THEME->GetPathTo("Graphics","select group explanation") );
|
2002-05-20 08:59:37 +00:00
|
|
|
m_sprExplanation.SetXY( EXPLANATION_X, EXPLANATION_Y );
|
2002-09-02 21:59:58 +00:00
|
|
|
this->AddChild( &m_sprExplanation );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-08-13 23:26:46 +00:00
|
|
|
// these guys get loaded SetSong and TweenToSong
|
|
|
|
|
m_Banner.SetXY( BANNER_X, BANNER_Y );
|
|
|
|
|
m_Banner.SetCroppedSize( BANNER_WIDTH, BANNER_HEIGHT );
|
2002-09-02 21:59:58 +00:00
|
|
|
this->AddChild( &m_Banner );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-08-13 23:26:46 +00:00
|
|
|
m_sprFrame.Load( THEME->GetPathTo("Graphics","select group info frame") );
|
|
|
|
|
m_sprFrame.SetXY( FRAME_X, FRAME_Y );
|
2002-09-02 21:59:58 +00:00
|
|
|
this->AddChild( &m_sprFrame );
|
2002-08-13 23:26:46 +00:00
|
|
|
|
2002-09-03 22:31:06 +00:00
|
|
|
m_textNumber.LoadFromFont( THEME->GetPathTo("Fonts","select group num songs") );
|
2002-08-13 23:26:46 +00:00
|
|
|
m_textNumber.SetXY( NUMBER_X, NUMBER_Y );
|
|
|
|
|
m_textNumber.SetHorizAlign( Actor::align_right );
|
|
|
|
|
m_textNumber.TurnShadowOff();
|
2002-09-02 21:59:58 +00:00
|
|
|
this->AddChild( &m_textNumber );
|
2002-08-13 23:26:46 +00:00
|
|
|
|
|
|
|
|
m_sprContents.Load( THEME->GetPathTo("Graphics","select group contents header") );
|
|
|
|
|
m_sprContents.SetXY( CONTENTS_X, CONTENTS_Y );
|
2002-09-02 21:59:58 +00:00
|
|
|
this->AddChild( &m_sprContents );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-09-02 21:59:58 +00:00
|
|
|
this->AddChild( &m_MusicList );
|
2002-08-24 20:36:29 +00:00
|
|
|
|
2002-10-31 03:01:35 +00:00
|
|
|
for( i=0; i < asGroupNames.size(); ++i )
|
2002-08-24 20:36:29 +00:00
|
|
|
m_GroupList.AddGroup( asGroupNames[i] );
|
|
|
|
|
m_GroupList.DoneAddingGroups();
|
2002-09-02 21:59:58 +00:00
|
|
|
this->AddChild( &m_GroupList );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
|
|
|
|
|
2002-08-13 23:26:46 +00:00
|
|
|
m_soundChange.Load( THEME->GetPathTo("Sounds","select group change") );
|
|
|
|
|
m_soundSelect.Load( THEME->GetPathTo("Sounds","menu start") );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2003-01-02 08:13:34 +00:00
|
|
|
SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("select group intro") );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2003-01-02 07:39:58 +00:00
|
|
|
SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","select group music") );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-05-28 20:01:22 +00:00
|
|
|
m_Menu.TweenOnScreenFromMenu( SM_None );
|
2002-05-20 08:59:37 +00:00
|
|
|
TweenOnScreen();
|
|
|
|
|
AfterChange();
|
2002-08-24 20:36:29 +00:00
|
|
|
m_GroupList.SetSelection(0);
|
2002-05-20 08:59:37 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ScreenSelectGroup::~ScreenSelectGroup()
|
|
|
|
|
{
|
2002-07-31 19:40:40 +00:00
|
|
|
LOG->Trace( "ScreenSelectGroup::~ScreenSelectGroup()" );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void ScreenSelectGroup::Input( const DeviceInput& DeviceI, const InputEventType type, const GameInput &GameI, const MenuInput &MenuI, const StyleInput &StyleI )
|
|
|
|
|
{
|
2002-07-31 19:40:40 +00:00
|
|
|
LOG->Trace( "ScreenSelectGroup::Input()" );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-05-28 20:01:22 +00:00
|
|
|
if( m_Menu.IsClosing() || m_bChosen )
|
2002-05-20 08:59:37 +00:00
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
Screen::Input( DeviceI, type, GameI, MenuI, StyleI ); // default input handler
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ScreenSelectGroup::DrawPrimitives()
|
|
|
|
|
{
|
|
|
|
|
m_Menu.DrawBottomLayer();
|
|
|
|
|
Screen::DrawPrimitives();
|
|
|
|
|
m_Menu.DrawTopLayer();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ScreenSelectGroup::HandleScreenMessage( const ScreenMessage SM )
|
|
|
|
|
{
|
|
|
|
|
switch( SM )
|
|
|
|
|
{
|
2002-05-27 08:23:27 +00:00
|
|
|
case SM_MenuTimer:
|
|
|
|
|
MenuStart(PLAYER_1);
|
|
|
|
|
break;
|
2002-08-27 23:31:41 +00:00
|
|
|
case SM_GoToPrevScreen:
|
2002-08-27 03:59:22 +00:00
|
|
|
SCREENMAN->SetNewScreen( "ScreenTitleMenu" );
|
2002-05-20 08:59:37 +00:00
|
|
|
break;
|
2002-08-27 23:31:41 +00:00
|
|
|
case SM_GoToNextScreen:
|
2002-08-28 22:42:40 +00:00
|
|
|
SCREENMAN->SetNewScreen( NEXT_SCREEN );
|
2002-05-20 08:59:37 +00:00
|
|
|
break;
|
|
|
|
|
case SM_StartFadingOut:
|
2002-08-27 23:31:41 +00:00
|
|
|
m_Menu.TweenOffScreenToMenu( SM_GoToNextScreen );
|
2002-05-20 08:59:37 +00:00
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ScreenSelectGroup::AfterChange()
|
|
|
|
|
{
|
2002-08-24 20:36:29 +00:00
|
|
|
int sel = m_GroupList.GetSelection();
|
|
|
|
|
m_MusicList.SetGroupNo(sel);
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-08-24 20:36:29 +00:00
|
|
|
CString sSelectedGroupName = m_GroupList.GetSelectionName();
|
2002-05-20 08:59:37 +00:00
|
|
|
|
|
|
|
|
CString sGroupBannerPath;
|
|
|
|
|
if( 0 == stricmp(sSelectedGroupName, "ALL MUSIC") )
|
2002-08-13 23:26:46 +00:00
|
|
|
sGroupBannerPath = THEME->GetPathTo("Graphics","all music banner");
|
2002-05-20 08:59:37 +00:00
|
|
|
else if( SONGMAN->GetGroupBannerPath(sSelectedGroupName) != "" )
|
|
|
|
|
sGroupBannerPath = SONGMAN->GetGroupBannerPath(sSelectedGroupName);
|
|
|
|
|
else
|
2002-08-13 23:26:46 +00:00
|
|
|
sGroupBannerPath = THEME->GetPathTo("Graphics","fallback banner");
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-08-24 06:30:32 +00:00
|
|
|
const int iNumSongs = m_MusicList.GetNumSongs();
|
2002-08-13 23:26:46 +00:00
|
|
|
m_textNumber.SetText( ssprintf("%d", iNumSongs) );
|
|
|
|
|
|
2003-01-02 03:00:53 +00:00
|
|
|
m_Banner.LoadFromGroup( sSelectedGroupName );
|
2002-05-20 08:59:37 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
2002-09-04 03:49:08 +00:00
|
|
|
void ScreenSelectGroup::MenuLeft( PlayerNumber pn )
|
2002-05-20 08:59:37 +00:00
|
|
|
{
|
2002-09-04 03:49:08 +00:00
|
|
|
MenuUp( pn );
|
2002-05-20 08:59:37 +00:00
|
|
|
}
|
|
|
|
|
|
2002-09-04 03:49:08 +00:00
|
|
|
void ScreenSelectGroup::MenuRight( PlayerNumber pn )
|
2002-05-20 08:59:37 +00:00
|
|
|
{
|
2002-09-04 03:49:08 +00:00
|
|
|
MenuDown( pn );
|
2002-05-20 08:59:37 +00:00
|
|
|
}
|
|
|
|
|
|
2002-09-04 03:49:08 +00:00
|
|
|
void ScreenSelectGroup::MenuUp( PlayerNumber pn )
|
2002-05-20 08:59:37 +00:00
|
|
|
{
|
|
|
|
|
if( m_bChosen )
|
|
|
|
|
return;
|
|
|
|
|
|
2002-08-24 20:36:29 +00:00
|
|
|
m_GroupList.Up();
|
2002-05-20 08:59:37 +00:00
|
|
|
|
|
|
|
|
AfterChange();
|
|
|
|
|
|
|
|
|
|
m_soundChange.PlayRandom();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
2002-09-04 03:49:08 +00:00
|
|
|
void ScreenSelectGroup::MenuDown( PlayerNumber pn )
|
2002-05-20 08:59:37 +00:00
|
|
|
{
|
|
|
|
|
if( m_bChosen )
|
|
|
|
|
return;
|
|
|
|
|
|
2002-08-24 20:36:29 +00:00
|
|
|
m_GroupList.Down();
|
2002-05-20 08:59:37 +00:00
|
|
|
|
|
|
|
|
AfterChange();
|
|
|
|
|
|
|
|
|
|
m_soundChange.PlayRandom();
|
|
|
|
|
}
|
|
|
|
|
|
2002-09-04 03:49:08 +00:00
|
|
|
void ScreenSelectGroup::MenuStart( PlayerNumber pn )
|
2002-05-20 08:59:37 +00:00
|
|
|
{
|
|
|
|
|
m_soundSelect.PlayRandom();
|
|
|
|
|
m_bChosen = true;
|
|
|
|
|
|
2002-07-23 01:41:40 +00:00
|
|
|
GAMESTATE->m_pCurSong = NULL;
|
2002-08-24 20:36:29 +00:00
|
|
|
GAMESTATE->m_sPreferredGroup = m_GroupList.GetSelectionName();
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-07-23 01:41:40 +00:00
|
|
|
if( 0 == stricmp(GAMESTATE->m_sPreferredGroup, "All Music") )
|
2003-01-02 08:13:34 +00:00
|
|
|
SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("select group comment all music") );
|
2002-05-20 08:59:37 +00:00
|
|
|
else
|
2003-01-02 08:13:34 +00:00
|
|
|
SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("select group comment general") );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
TweenOffScreen();
|
2002-08-20 21:00:56 +00:00
|
|
|
m_Menu.StopTimer();
|
2002-05-28 20:01:22 +00:00
|
|
|
|
2002-05-20 08:59:37 +00:00
|
|
|
this->SendScreenMessage( SM_StartFadingOut, 0.8f );
|
|
|
|
|
}
|
|
|
|
|
|
2002-09-04 03:49:08 +00:00
|
|
|
void ScreenSelectGroup::MenuBack( PlayerNumber pn )
|
2002-05-20 08:59:37 +00:00
|
|
|
{
|
2002-08-27 23:31:41 +00:00
|
|
|
m_Menu.TweenOffScreenToBlack( SM_GoToPrevScreen, true );
|
2002-05-20 08:59:37 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ScreenSelectGroup::TweenOffScreen()
|
|
|
|
|
{
|
2002-09-02 21:59:58 +00:00
|
|
|
m_sprExplanation.BeginTweening( 0.8f );
|
|
|
|
|
m_sprExplanation.BeginTweening( 0.5f, TWEEN_BOUNCE_BEGIN );
|
2002-05-20 08:59:37 +00:00
|
|
|
m_sprExplanation.SetTweenX( EXPLANATION_X-400 );
|
|
|
|
|
|
2002-08-13 23:26:46 +00:00
|
|
|
Actor* pActorsInGroupInfoFrame[] = { &m_sprFrame, &m_Banner, &m_textNumber };
|
|
|
|
|
const int iNumActorsInGroupInfoFrame = sizeof(pActorsInGroupInfoFrame) / sizeof(Actor*);
|
|
|
|
|
for( int i=0; i<iNumActorsInGroupInfoFrame; i++ )
|
|
|
|
|
{
|
2002-09-02 21:59:58 +00:00
|
|
|
pActorsInGroupInfoFrame[i]->BeginTweening( 0.9f );
|
|
|
|
|
pActorsInGroupInfoFrame[i]->BeginTweening( 0.5f, TWEEN_BOUNCE_BEGIN );
|
2002-08-13 23:26:46 +00:00
|
|
|
pActorsInGroupInfoFrame[i]->SetTweenX( pActorsInGroupInfoFrame[i]->GetX()-400 );
|
|
|
|
|
}
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-09-02 21:59:58 +00:00
|
|
|
m_sprContents.BeginTweening( 0.7f );
|
|
|
|
|
m_sprContents.BeginTweening( 0.5f, TWEEN_BIAS_END );
|
2002-08-13 23:26:46 +00:00
|
|
|
m_sprContents.SetTweenY( CONTENTS_Y+400 );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-08-24 06:30:32 +00:00
|
|
|
m_MusicList.TweenOffScreen();
|
2002-08-24 20:36:29 +00:00
|
|
|
m_GroupList.TweenOffScreen();
|
2002-05-20 08:59:37 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ScreenSelectGroup::TweenOnScreen()
|
|
|
|
|
{
|
|
|
|
|
m_sprExplanation.SetX( EXPLANATION_X-400 );
|
|
|
|
|
m_sprExplanation.BeginTweening( 0.5f, TWEEN_BOUNCE_END );
|
|
|
|
|
m_sprExplanation.SetTweenX( EXPLANATION_X );
|
|
|
|
|
|
2002-08-13 23:26:46 +00:00
|
|
|
Actor* pActorsInGroupInfoFrame[] = { &m_sprFrame, &m_Banner, &m_textNumber };
|
|
|
|
|
const int iNumActorsInGroupInfoFrame = sizeof(pActorsInGroupInfoFrame) / sizeof(Actor*);
|
|
|
|
|
for( int i=0; i<iNumActorsInGroupInfoFrame; i++ )
|
|
|
|
|
{
|
|
|
|
|
float fOriginalX = pActorsInGroupInfoFrame[i]->GetX();
|
|
|
|
|
pActorsInGroupInfoFrame[i]->SetX( fOriginalX-400 );
|
|
|
|
|
pActorsInGroupInfoFrame[i]->BeginTweening( 0.5f, TWEEN_BOUNCE_END );
|
|
|
|
|
pActorsInGroupInfoFrame[i]->SetTweenX( fOriginalX );
|
|
|
|
|
}
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-08-13 23:26:46 +00:00
|
|
|
m_sprContents.SetY( CONTENTS_Y+400 );
|
2002-09-02 21:59:58 +00:00
|
|
|
m_sprContents.BeginTweening( 0.5f, TWEEN_BIAS_END ); // sleep
|
|
|
|
|
m_sprContents.BeginTweening( 0.5f, TWEEN_BIAS_END );
|
2002-08-13 23:26:46 +00:00
|
|
|
m_sprContents.SetTweenY( CONTENTS_Y );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-08-24 06:30:32 +00:00
|
|
|
m_MusicList.TweenOnScreen();
|
2002-08-24 20:36:29 +00:00
|
|
|
m_GroupList.TweenOnScreen();
|
2002-05-20 08:59:37 +00:00
|
|
|
}
|