Deal with determining whether to use Marv. timing within TNStoDP.
Use IsCourseMode. Remove old comment.
This commit is contained in:
@@ -11,10 +11,17 @@
|
||||
*/
|
||||
|
||||
#include "GameConstantsAndTypes.h"
|
||||
#include "PrefsManager.h"
|
||||
#include "GameState.h"
|
||||
|
||||
|
||||
int TapNoteScoreToDancePoints( TapNoteScore tns, bool bOni )
|
||||
/* XXX: Should this be in GAMESTATE? It's not really a constant anymore. */
|
||||
int TapNoteScoreToDancePoints( TapNoteScore tns )
|
||||
{
|
||||
const bool bOni = GAMESTATE->IsCourseMode();
|
||||
|
||||
if(!PREFSMAN->m_bMarvelousTiming && tns == TNS_MARVELOUS)
|
||||
tns = TNS_PERFECT;
|
||||
|
||||
switch( tns )
|
||||
{
|
||||
case TNS_MARVELOUS: return bOni ? +3 : +2;
|
||||
|
||||
@@ -124,7 +124,7 @@ enum TapNoteScore {
|
||||
NUM_TAP_NOTE_SCORES
|
||||
};
|
||||
|
||||
int TapNoteScoreToDancePoints( TapNoteScore tns, bool bOni = false );
|
||||
int TapNoteScoreToDancePoints( TapNoteScore tns );
|
||||
|
||||
//enum TapNoteTiming {
|
||||
// TNT_NONE,
|
||||
|
||||
@@ -327,28 +327,12 @@ int NoteData::GetPossibleDancePoints()
|
||||
//An "OK" (Successful Freeze step) will add 6 points
|
||||
//A "NG" (Unsuccessful Freeze step) is worth 0 points
|
||||
|
||||
if(PREFSMAN->m_bMarvelousTiming && ( GAMESTATE->m_PlayMode == PLAY_MODE_ONI || GAMESTATE->m_PlayMode == PLAY_MODE_NONSTOP || GAMESTATE->m_PlayMode == PLAY_MODE_ENDLESS ) ) // score out of marvelous for course modes, unless marvelous timing is off
|
||||
{
|
||||
return GetNumTapNotes()*TapNoteScoreToDancePoints(TNS_MARVELOUS) + // Marvelous for oni
|
||||
GetNumHoldNotes()*HoldNoteScoreToDancePoints(HNS_OK);
|
||||
}
|
||||
|
||||
return GetNumTapNotes()*TapNoteScoreToDancePoints(TNS_PERFECT) + // not Marvelous
|
||||
/* Note that, if Marvelous timing is disabled or not active (not course mode),
|
||||
* PERFECT will be used instead. */
|
||||
return GetNumTapNotes()*TapNoteScoreToDancePoints(TNS_MARVELOUS)+
|
||||
GetNumHoldNotes()*HoldNoteScoreToDancePoints(HNS_OK);
|
||||
}
|
||||
|
||||
/* ConvertHoldNotesTo2sAnd3s also clears m_iHoldNotes;
|
||||
* shouldn't this do likewise and set all 2/3's to 0?
|
||||
* -glenn
|
||||
*
|
||||
* Other code assumes != TAP_EMPTY means there's a tap note, so I changed
|
||||
* this to do this. -glenn
|
||||
*
|
||||
|
||||
* This code intentially leaves the TAP_HOLD_HEAD behind because a hold head is
|
||||
* treated exactly like a tap note for scoring purposes.
|
||||
|
||||
*/
|
||||
void NoteData::Convert2sAnd3sToHoldNotes()
|
||||
{
|
||||
// Any note will end a hold (not just a TAP_HOLD_TAIL). This makes parsing DWIs much easier.
|
||||
|
||||
@@ -51,7 +51,7 @@ void ScoreKeeperMAX2::HandleTapScore( TapNoteScore score, int iNumTapsInRow )
|
||||
ASSERT( iNumTapsInRow >= 1 );
|
||||
|
||||
// update dance points for Oni lifemeter
|
||||
GAMESTATE->m_CurStageStats.iActualDancePoints[m_PlayerNumber] += iNumTapsInRow * TapNoteScoreToDancePoints( score, GAMESTATE->m_PlayMode == PLAY_MODE_ONI || GAMESTATE->m_PlayMode == PLAY_MODE_NONSTOP || GAMESTATE->m_PlayMode == PLAY_MODE_ENDLESS );
|
||||
GAMESTATE->m_CurStageStats.iActualDancePoints[m_PlayerNumber] += iNumTapsInRow * TapNoteScoreToDancePoints( score );
|
||||
GAMESTATE->m_CurStageStats.iTapNoteScores[m_PlayerNumber][score] += iNumTapsInRow;
|
||||
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user