clear all stage stats to fix accumulating life and combo memory

This commit is contained in:
Chris Danford
2005-04-04 12:45:35 +00:00
parent 8b5f3c3e55
commit 00e4c2686e
3 changed files with 12 additions and 3 deletions
+6 -1
View File
@@ -5,7 +5,7 @@
#include "Steps.h"
#include "song.h"
void StageStats::Init()
StageStats::StageStats()
{
playMode = PLAY_MODE_INVALID;
pStyle = NULL;
@@ -14,6 +14,11 @@ void StageStats::Init()
fGameplaySeconds = 0;
}
void StageStats::Init()
{
*this = StageStats();
}
void StageStats::AssertValid( PlayerNumber pn ) const
{
ASSERT( vpSongs.size() != 0 );
+1 -1
View File
@@ -12,7 +12,7 @@ struct lua_State;
struct StageStats
{
StageStats() { Init(); }
StageStats();
void Init();
void AssertValid( PlayerNumber pn ) const;
+5 -1
View File
@@ -12,11 +12,15 @@ public:
void Reset()
{
m_CurStageStats.Init();
m_vPlayedStageStats.clear();
m_AccumStageStats.Init();
m_FinalEvalStageStats.Init();
CalcAccumStageStats();
}
StageStats m_CurStageStats; // current stage (not necessarily passed if Extra Stage)
StageStats m_CurStageStats; // current stage (not necessarily passed if Extra Stage)
vector<StageStats> m_vPlayedStageStats;
// Only the latest 3 normal songs + passed extra stages.