save and restore last used ranking name from/to profile

This commit is contained in:
Chris Danford
2003-11-09 10:14:52 +00:00
parent 2920700f7a
commit 7681bd508b
4 changed files with 33 additions and 7 deletions
@@ -29,6 +29,7 @@
#include "AnnouncerManager.h"
#include "song.h"
#include <math.h>
#include "ProfileManager.h"
//
@@ -419,6 +420,11 @@ void ScreenNameEntryTraditional::Finish( PlayerNumber pn )
GAMESTATE->StoreRankingName( pn, selection );
// save last used ranking name
Profile* pProfile = PROFILEMAN->GetProfile(pn);
if( pProfile )
pProfile->m_sLastUsedHighScoreName = selection;
OFF_COMMAND( m_Keyboard[pn] );
for( int i = 0; i < (int)m_textAlphabet[pn].size(); ++i )
OFF_COMMAND( m_textAlphabet[pn][i] );