silence a bunch of msvc warnings
This commit is contained in:
+1
-1
@@ -447,7 +447,7 @@ void BackgroundImpl::LoadFromRandom( float fFirstBeat, float fEndBeat, const Bac
|
|||||||
int time_signature_start= max(ts->GetRow(),iStartRow);
|
int time_signature_start= max(ts->GetRow(),iStartRow);
|
||||||
for(int j= time_signature_start;
|
for(int j= time_signature_start;
|
||||||
j<min(iEndRow,iSegmentEndRow);
|
j<min(iEndRow,iSegmentEndRow);
|
||||||
j+= RAND_BG_CHANGE_MEASURES * ts->GetNoteRowsPerMeasure())
|
j+= int(RAND_BG_CHANGE_MEASURES * ts->GetNoteRowsPerMeasure()))
|
||||||
{
|
{
|
||||||
// Don't fade. It causes frame rate dip, especially on slower machines.
|
// Don't fade. It causes frame rate dip, especially on slower machines.
|
||||||
BackgroundDef bd = m_Layer[0].CreateRandomBGA(m_pSong,
|
BackgroundDef bd = m_Layer[0].CreateRandomBGA(m_pSong,
|
||||||
|
|||||||
+1
-1
@@ -713,7 +713,7 @@ void Course::GetTrailUnsortedEndless( const vector<CourseEntry> &entries, Trail
|
|||||||
ASSERT( e->iChooseIndex >= 0 );
|
ASSERT( e->iChooseIndex >= 0 );
|
||||||
if( e->iChooseIndex < int( vSongAndSteps.size() ) )
|
if( e->iChooseIndex < int( vSongAndSteps.size() ) )
|
||||||
{
|
{
|
||||||
if( songIndex >= vpSongs.size() ) {
|
if( songIndex >= int(vpSongs.size()) ) {
|
||||||
songIndex = 0;
|
songIndex = 0;
|
||||||
}
|
}
|
||||||
resolved.pSong = vpSongs[ songIndex ];
|
resolved.pSong = vpSongs[ songIndex ];
|
||||||
|
|||||||
@@ -70,7 +70,7 @@ void CourseContentsList::SetFromGameState()
|
|||||||
if( bLoop )
|
if( bLoop )
|
||||||
{
|
{
|
||||||
SetPauseCountdownSeconds( 1.5f );
|
SetPauseCountdownSeconds( 1.5f );
|
||||||
this->SetDestinationItem( m_vpDisplay.size()+1 ); // loop forever
|
this->SetDestinationItem( (float)m_vpDisplay.size()+1 ); // loop forever
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -314,7 +314,7 @@ static void DoPlayOnceFromDir( RString sPath )
|
|||||||
// If order is exhausted, repopulate and reshuffle
|
// If order is exhausted, repopulate and reshuffle
|
||||||
if (order.size() == 0)
|
if (order.size() == 0)
|
||||||
{
|
{
|
||||||
for (int i = 0; i < arraySoundFiles.size(); ++i)
|
for (int i = 0; i < (int)arraySoundFiles.size(); ++i)
|
||||||
{
|
{
|
||||||
order.push_back(i);
|
order.push_back(i);
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -107,7 +107,7 @@ void GrooveRadar::GrooveRadarValueMap::SetFromSteps( const RadarValues &rv )
|
|||||||
{
|
{
|
||||||
const float fValueCurrent = m_fValuesOld[c] * (1-m_PercentTowardNew) + m_fValuesNew[c] * m_PercentTowardNew;
|
const float fValueCurrent = m_fValuesOld[c] * (1-m_PercentTowardNew) + m_fValuesNew[c] * m_PercentTowardNew;
|
||||||
m_fValuesOld[c] = fValueCurrent;
|
m_fValuesOld[c] = fValueCurrent;
|
||||||
m_fValuesNew[c] = clamp(rv[c], 0.0, 1.0);
|
m_fValuesNew[c] = (int)clamp(rv[c], 0.0, 1.0);
|
||||||
}
|
}
|
||||||
|
|
||||||
if( !m_bValuesVisible ) // the values WERE invisible
|
if( !m_bValuesVisible ) // the values WERE invisible
|
||||||
|
|||||||
@@ -100,7 +100,7 @@ void LifeMeterBattery::OnSongEnded()
|
|||||||
LuaHelpers::Push(L, pn);
|
LuaHelpers::Push(L, pn);
|
||||||
RString error= "Error running CourseSongRewardLives callback: ";
|
RString error= "Error running CourseSongRewardLives callback: ";
|
||||||
LuaHelpers::RunScriptOnStack(L, error, 2, 1, true);
|
LuaHelpers::RunScriptOnStack(L, error, 2, 1, true);
|
||||||
m_iLivesLeft += luaL_optnumber(L, -1, 0);
|
m_iLivesLeft += (int)luaL_optnumber(L, -1, 0);
|
||||||
lua_settop(L, 0);
|
lua_settop(L, 0);
|
||||||
LUA->Release(L);
|
LUA->Release(L);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1063,15 +1063,15 @@ public:
|
|||||||
lua_pop( L, 1 );
|
lua_pop( L, 1 );
|
||||||
|
|
||||||
lua_getfield(L, -1, "GoToFirstOnStart");
|
lua_getfield(L, -1, "GoToFirstOnStart");
|
||||||
m_GoToFirstOnStart= lua_toboolean(L, -1);
|
m_GoToFirstOnStart = lua_toboolean(L, -1) > 0;
|
||||||
lua_pop(L, 1);
|
lua_pop(L, 1);
|
||||||
|
|
||||||
lua_getfield(L, -1, "OneChoiceForAllPlayers");
|
lua_getfield(L, -1, "OneChoiceForAllPlayers");
|
||||||
m_Def.m_bOneChoiceForAllPlayers = lua_toboolean( L, -1 );
|
m_Def.m_bOneChoiceForAllPlayers = lua_toboolean( L, -1 ) > 0;
|
||||||
lua_pop( L, 1 );
|
lua_pop( L, 1 );
|
||||||
|
|
||||||
lua_getfield(L, -1, "ExportOnChange");
|
lua_getfield(L, -1, "ExportOnChange");
|
||||||
m_Def.m_bExportOnChange = lua_toboolean( L, -1 );
|
m_Def.m_bExportOnChange = lua_toboolean( L, -1 ) > 0;
|
||||||
lua_pop( L, 1 );
|
lua_pop( L, 1 );
|
||||||
|
|
||||||
// TODO: Change these to use the proper enum strings like everything
|
// TODO: Change these to use the proper enum strings like everything
|
||||||
|
|||||||
+1
-1
@@ -1081,7 +1081,7 @@ public:
|
|||||||
ADD_METHOD( GetCumFPS );
|
ADD_METHOD( GetCumFPS );
|
||||||
ADD_METHOD( GetDisplaySpecs );
|
ADD_METHOD( GetDisplaySpecs );
|
||||||
ADD_METHOD( SupportsRenderToTexture );
|
ADD_METHOD( SupportsRenderToTexture );
|
||||||
ADD_METHOD( SupportsFullscreenBorderlessWindow);
|
ADD_METHOD( SupportsFullscreenBorderlessWindow );
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -209,8 +209,8 @@ void ScreenEvaluation::Init()
|
|||||||
case RadarCategory_Rolls:
|
case RadarCategory_Rolls:
|
||||||
case RadarCategory_Lifts:
|
case RadarCategory_Lifts:
|
||||||
case RadarCategory_Fakes:
|
case RadarCategory_Fakes:
|
||||||
ss.m_player[p].m_radarPossible[rc] = 1 + (rand() % 200);
|
ss.m_player[p].m_radarPossible[rc] = float(1 + (rand() % 200));
|
||||||
ss.m_player[p].m_radarActual[rc] = rand() % (int)(ss.m_player[p].m_radarPossible[rc]);
|
ss.m_player[p].m_radarActual[rc] = float(rand() % (int)(ss.m_player[p].m_radarPossible[rc]));
|
||||||
break;
|
break;
|
||||||
default: break;
|
default: break;
|
||||||
}
|
}
|
||||||
@@ -270,13 +270,13 @@ void ScreenEvaluation::Init()
|
|||||||
|
|
||||||
m_SmallBanner[i].LoadFromSong( pSong );
|
m_SmallBanner[i].LoadFromSong( pSong );
|
||||||
m_SmallBanner[i].ScaleToClipped( BANNER_WIDTH, BANNER_HEIGHT );
|
m_SmallBanner[i].ScaleToClipped( BANNER_WIDTH, BANNER_HEIGHT );
|
||||||
m_SmallBanner[i].SetName( ssprintf("SmallBanner%zu",i+1) );
|
m_SmallBanner[i].SetName( ssprintf("SmallBanner%u",(unsigned)i+1) );
|
||||||
ActorUtil::LoadAllCommands( m_SmallBanner[i], m_sName );
|
ActorUtil::LoadAllCommands( m_SmallBanner[i], m_sName );
|
||||||
SET_XY( m_SmallBanner[i] );
|
SET_XY( m_SmallBanner[i] );
|
||||||
this->AddChild( &m_SmallBanner[i] );
|
this->AddChild( &m_SmallBanner[i] );
|
||||||
|
|
||||||
m_sprSmallBannerFrame[i].Load( THEME->GetPathG(m_sName,"BannerFrame") );
|
m_sprSmallBannerFrame[i].Load( THEME->GetPathG(m_sName,"BannerFrame") );
|
||||||
m_sprSmallBannerFrame[i]->SetName( ssprintf("SmallBanner%zu",i+1) );
|
m_sprSmallBannerFrame[i]->SetName( ssprintf("SmallBanner%u",(unsigned)i+1) );
|
||||||
ActorUtil::LoadAllCommands( *m_sprSmallBannerFrame[i], m_sName );
|
ActorUtil::LoadAllCommands( *m_sprSmallBannerFrame[i], m_sName );
|
||||||
SET_XY( m_sprSmallBannerFrame[i] );
|
SET_XY( m_sprSmallBannerFrame[i] );
|
||||||
this->AddChild( m_sprSmallBannerFrame[i] );
|
this->AddChild( m_sprSmallBannerFrame[i] );
|
||||||
@@ -548,7 +548,7 @@ void ScreenEvaluation::Init()
|
|||||||
DEFAULT_FAIL( l );
|
DEFAULT_FAIL( l );
|
||||||
}
|
}
|
||||||
|
|
||||||
m_textJudgmentLineNumber[l][p].SetTargetNumber( iValue );
|
m_textJudgmentLineNumber[l][p].SetTargetNumber( float(iValue) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -607,7 +607,7 @@ void ScreenEvaluation::Init()
|
|||||||
m_textScore[p].Load( "RollingNumbersEvaluation" );
|
m_textScore[p].Load( "RollingNumbersEvaluation" );
|
||||||
ActorUtil::LoadAllCommands( m_textScore[p], m_sName );
|
ActorUtil::LoadAllCommands( m_textScore[p], m_sName );
|
||||||
SET_XY( m_textScore[p] );
|
SET_XY( m_textScore[p] );
|
||||||
m_textScore[p].SetTargetNumber( m_pStageStats->m_player[p].m_iScore );
|
m_textScore[p].SetTargetNumber( float(m_pStageStats->m_player[p].m_iScore) );
|
||||||
this->AddChild( &m_textScore[p] );
|
this->AddChild( &m_textScore[p] );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -311,7 +311,7 @@ void ScreenOptionsEditCourse::ExportOptions( int iRow, const vector<PlayerNumber
|
|||||||
GAMESTATE->m_pCurCourse->m_fGoalSeconds = 0;
|
GAMESTATE->m_pCurCourse->m_fGoalSeconds = 0;
|
||||||
int mins;
|
int mins;
|
||||||
if( sscanf( sValue, "%d", &mins ) == 1 )
|
if( sscanf( sValue, "%d", &mins ) == 1 )
|
||||||
GAMESTATE->m_pCurCourse->m_fGoalSeconds = mins * 60;
|
GAMESTATE->m_pCurCourse->m_fGoalSeconds = float(mins * 60);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-2
@@ -1628,8 +1628,8 @@ int LuaFunc_SaveScreenshot(lua_State *L)
|
|||||||
// If pn is provided, save to that player's profile.
|
// If pn is provided, save to that player's profile.
|
||||||
// Otherwise, save to the machine.
|
// Otherwise, save to the machine.
|
||||||
PlayerNumber pn= Enum::Check<PlayerNumber>(L, 1, true);
|
PlayerNumber pn= Enum::Check<PlayerNumber>(L, 1, true);
|
||||||
bool compress= lua_toboolean(L, 2);
|
bool compress= lua_toboolean(L, 2) > 0;
|
||||||
bool sign= lua_toboolean(L, 3);
|
bool sign= lua_toboolean(L, 3) > 0;
|
||||||
RString prefix= luaL_optstring(L, 4, "");
|
RString prefix= luaL_optstring(L, 4, "");
|
||||||
RString suffix= luaL_optstring(L, 5, "");
|
RString suffix= luaL_optstring(L, 5, "");
|
||||||
RString dir;
|
RString dir;
|
||||||
|
|||||||
Reference in New Issue
Block a user