Fix SongPosition variable initialization

Move SongPosition::Reset into the header file, and call it in the constructor.
This commit is contained in:
sukibaby
2024-09-12 23:43:50 -07:00
committed by teejusb
parent 659cd549a2
commit 1c46342a95
2 changed files with 36 additions and 46 deletions
-19
View File
@@ -37,25 +37,6 @@ void SongPosition::UpdateSongPosition( float fPositionSeconds, const TimingData
m_fSongBeatVisible= beat_info.beat;
}
void SongPosition::Reset()
{
m_fMusicSecondsVisible = 0;
m_fSongBeatVisible = 0;
m_fMusicSeconds = 0; // MUSIC_SECONDS_INVALID;
// todo: move me to FOREACH_EnabledPlayer( p ) after [NUM_PLAYERS]ing
m_fSongBeat = 0;
m_fSongBeatNoOffset = 0;
m_fCurBPS = 10;
//m_bStop = false;
m_bFreeze = false;
m_bDelay = false;
m_iWarpBeginRow = -1; // Set to -1 because some song may want to warp to row 0. -aj
m_fWarpDestination = -1; // Set when a warp is encountered. also see above. -aj
}
//lua start
#include "LuaBinding.h"
class LunaSongPosition: public Luna<SongPosition>