some more s/GetSize/size/ and other minor STLisms

This commit is contained in:
Glenn Maynard
2002-10-31 02:54:49 +00:00
parent 2b16872bd5
commit 945a39a247
11 changed files with 65 additions and 65 deletions
+3 -3
View File
@@ -36,7 +36,7 @@ TipDisplay::TipDisplay()
void TipDisplay::SetTips( CStringArray &arrayTips )
{
m_arrayTips = arrayTips;
if( m_arrayTips.GetSize() > 0 )
if( !m_arrayTips.empty() )
m_textTip.SetText( m_arrayTips[0] );
}
@@ -45,13 +45,13 @@ void TipDisplay::Update( float fDeltaTime )
{
ActorFrame::Update( fDeltaTime );
if( m_arrayTips.GetSize() > 0 )
if( !m_arrayTips.empty() )
{
m_fSecsUntilSwitch -= fDeltaTime;
if( m_fSecsUntilSwitch < 0 ) // time to switch states
{
m_iCurTipIndex++;
m_iCurTipIndex = m_iCurTipIndex % m_arrayTips.GetSize();
m_iCurTipIndex = m_iCurTipIndex % m_arrayTips.size();
m_fSecsUntilSwitch = TIP_SHOW_TIME;
m_textTip.SetText( m_arrayTips[m_iCurTipIndex] );
}