fix hidden, sudden when using reverse

This commit is contained in:
Chris Danford
2003-04-17 21:44:33 +00:00
parent d3048641b1
commit 7e46786e0d
3 changed files with 15 additions and 9 deletions
+6 -3
View File
@@ -138,11 +138,14 @@ const float fCenterLine = 160; // from fYPos == 0
const float fFadeDist = 100;
// used by ArrowGetAlpha and ArrowGetGlow below
float ArrowGetPercentVisible( PlayerNumber pn, float fYPosWithoutReverse )
float ArrowGetPercentVisible( PlayerNumber pn, float fYPos )
{
const float fDistFromCenterLine = fYPosWithoutReverse - fCenterLine;
if( GAMESTATE->m_CurrentPlayerOptions[pn].m_fReverseScroll > 0.5f )
fYPos *= -1;
if( fYPosWithoutReverse < 0 ) // past Gray Arrows
const float fDistFromCenterLine = fYPos - fCenterLine;
if( fYPos < 0 ) // past Gray Arrows
return 1; // totally visible
+8 -5
View File
@@ -153,6 +153,7 @@ void PlayerOptions::FromString( CString sOptions )
if( sBit == "0.25x" ) { /*m_bUseScrollBPM=false;*/ m_fScrollSpeed = 0.25f; }
else if( sBit == "0.5x" ) { /*m_bUseScrollBPM=false;*/ m_fScrollSpeed = 0.50f; }
else if( sBit == "0.75x" ) { /*m_bUseScrollBPM=false;*/ m_fScrollSpeed = 0.75f; }
else if( sBit == "1.5x" ) { /*m_bUseScrollBPM=false;*/ m_fScrollSpeed = 1.00f; }
else if( sBit == "2.0x" ) { /*m_bUseScrollBPM=false;*/ m_fScrollSpeed = 2.00f; }
else if( sBit == "3.0x" ) { /*m_bUseScrollBPM=false;*/ m_fScrollSpeed = 3.00f; }
@@ -201,7 +202,8 @@ void PlayerOptions::FromString( CString sOptions )
void NextFloat( float fValues[], int size )
{
int index = -1;
for( int i=0; i<size; i++ )
int i;
for( i=0; i<size; i++ )
{
if( fValues[i] == 1 )
{
@@ -210,13 +212,14 @@ void NextFloat( float fValues[], int size )
}
}
memset( fValues, 0, size );
for( i=0; i<size; i++ )
fValues[i] = 0;
index++;
if( index == size ) // if true, then the last float in the list was selected
index;
if( index == size-1 ) // if true, then the last float in the list was selected
; // leave all off
else
fValues[index] = 1;
fValues[index+1] = 1;
}
void PlayerOptions::NextAccel()
+1 -1
View File
@@ -46,7 +46,7 @@ OptionRow g_PlayerOptionsLines[NUM_PLAYER_OPTIONS_LINES] = {
OptionRow( "Scroll", "STANDARD","REVERSE" ),
OptionRow( "Note\nSkin", "" ),
OptionRow( "Holds", "OFF","ON" ),
OptionRow( "Other", "DARK","TIME SPACING" ),
OptionRow( "Other", "OFF","DARK","TIME SPACING" ),
OptionRow( "Perspec\n-tive", "INCOMING","OVERHEAD","SPACE" ),
};