Make the minimum score to stay alive be themeable.

This commit is contained in:
Steve Checkoway
2006-07-03 04:30:20 +00:00
parent 227d2d1575
commit ea1ec405e5
+2 -1
View File
@@ -42,6 +42,7 @@ static ThemeMetric<float> DANGER_THRESHOLD ("LifeMeterBar","DangerThreshold");
static ThemeMetric<int> NUM_CHAMBERS ("LifeMeterBar","NumChambers");
static ThemeMetric<int> NUM_STRIPS ("LifeMeterBar","NumStrips");
static ThemeMetric<float> INITIAL_VALUE ("LifeMeterBar","InitialValue");
static ThemeMetricEnum<TapNoteScore> MIN_STAY_ALIVE( "LifeMeterBar","MinStayAlive" );
const float FAIL_THRESHOLD = 0;
@@ -165,7 +166,7 @@ void LifeMeterBar::ChangeLife( TapNoteScore score )
fDeltaLife = min( fDeltaLife, 0 );
break;
case SongOptions::DRAIN_SUDDEN_DEATH:
if( fDeltaLife < 0 )
if( score < MIN_STAY_ALIVE )
fDeltaLife = -1.0f;
else
fDeltaLife = 0;