diff --git a/stepmania/src/Player.cpp b/stepmania/src/Player.cpp index 2fcd76659e..e81e492cbb 100644 --- a/stepmania/src/Player.cpp +++ b/stepmania/src/Player.cpp @@ -523,7 +523,7 @@ void PlayerMinus::DrawHoldJudgments() } /* It's OK for this function to search a little more than was requested. */ -int PlayerMinus::GetClosestNoteDirectional( int col, float fBeat, float fMaxBeatsDistance, int iDirection ) +int PlayerMinus::GetClosestNoteDirectional( int col, float fBeat, float fMaxBeatsDistance, int iDirection ) const { // look for the closest matching step const int iIndexStartLookingAt = BeatToNoteRow( fBeat ); @@ -547,7 +547,7 @@ int PlayerMinus::GetClosestNoteDirectional( int col, float fBeat, float fMaxBeat return -1; } -int PlayerMinus::GetClosestNote( int col, float fBeat, float fMaxBeatsAhead, float fMaxBeatsBehind ) +int PlayerMinus::GetClosestNote( int col, float fBeat, float fMaxBeatsAhead, float fMaxBeatsBehind ) const { int Fwd = GetClosestNoteDirectional(col, fBeat, fMaxBeatsAhead, 1); int Back = GetClosestNoteDirectional(col, fBeat, fMaxBeatsBehind, -1); @@ -1231,6 +1231,7 @@ void PlayerMinus::FadeToFail() m_pNoteField->FadeToFail(); } +/* XXX: Why's m_NoteField in a separate class, again? Is that still needed? */ void Player::Load( PlayerNumber player_no, const NoteData* pNoteData, LifeMeter* pLM, CombinedLifeMeter* pCombinedLM, ScoreDisplay* pScoreDisplay, ScoreDisplay* pSecondaryScoreDisplay, Inventory* pInventory, ScoreKeeper* pPrimaryScoreKeeper, ScoreKeeper* pSecondaryScoreKeeper ) { PlayerMinus::Load( player_no, pNoteData, pLM, pCombinedLM, pScoreDisplay, pSecondaryScoreDisplay, pInventory, pPrimaryScoreKeeper, pSecondaryScoreKeeper, &m_NoteField ); diff --git a/stepmania/src/Player.h b/stepmania/src/Player.h index c7472d667e..490119266f 100644 --- a/stepmania/src/Player.h +++ b/stepmania/src/Player.h @@ -53,7 +53,7 @@ public: void Step( int col, RageTimer tm ); void RandomiseNotes( int iNoteRow ); void FadeToFail(); - int GetDancingCharacterState() { return m_iDCState; }; + int GetDancingCharacterState() const { return m_iDCState; }; void SetCharacterState(int iDCState) { m_iDCState = iDCState; }; void ApplyWaitingTransforms(); @@ -66,8 +66,8 @@ protected: void DrawTapJudgments(); void DrawHoldJudgments(); - int GetClosestNoteDirectional( int col, float fBeat, float fMaxBeatsAhead, int iDirection ); - int GetClosestNote( int col, float fBeat, float fMaxBeatsAhead, float fMaxBeatsBehind ); + int GetClosestNoteDirectional( int col, float fBeat, float fMaxBeatsAhead, int iDirection ) const; + int GetClosestNote( int col, float fBeat, float fMaxBeatsAhead, float fMaxBeatsBehind ) const; static float GetMaxStepDistanceSeconds();