diff --git a/stepmania/src/RollingNumbers.cpp b/stepmania/src/RollingNumbers.cpp index 95439780c0..7e5ca2de13 100644 --- a/stepmania/src/RollingNumbers.cpp +++ b/stepmania/src/RollingNumbers.cpp @@ -36,11 +36,18 @@ void RollingNumbers::DrawPrimitives() RString s = this->GetText(); int i; + // find the first non-zero, non-comma character for( i=0; i<(int)s.length(); i++ ) { if( s[i] != '0' && s[i] != ',' ) break; } + // Rewind to the first number, even if it's a zero. If the string is "0000", we want the last zero to show in the regular color. + for( ; i>=0; i-- ) + { + if( s[i] >= '0' && s[i] <= '9' ) + break; + } float f = i / (float)s.length(); // draw leading part