Added interface for controlling the behavior of the hasts system. Added support for negative haste. Moves haste rate calculations to UpdateHasteRate. GetHasteRate now just returns the calculated value. Added FLOAT_NO_SPEED_INTERFACE and FLOAT_TABLE_INTERFACE macros to OptionsBinding.h

This commit is contained in:
Kyzentun
2014-05-05 14:16:08 -06:00
parent b10c04c7f3
commit ec3e76277c
7 changed files with 297 additions and 17 deletions
+9
View File
@@ -172,6 +172,11 @@ public:
bool IsPaused() const { return m_bPaused; }
float GetHasteRate();
vector<float> m_HasteTurningPoints; // Values at which the meaning of GAMESTATE->m_fHasteRate changes.
vector<float> m_HasteAddAmounts; // Amounts that are added to speed depending on what turning point has been passed.
float m_fHasteTimeBetweenUpdates; // Seconds between haste updates.
float m_fHasteLifeSwitchPoint; // Life amount below which GAMESTATE->m_fHasteRate is based on the life amount.
protected:
virtual void UpdateStageStats( MultiPlayer /* mp */ ) {}; // overridden for multiplayer
@@ -227,6 +232,10 @@ protected:
virtual void InitSongQueues();
void UpdateHasteRate();
float m_fCurrHasteRate;
// These exist so that the haste rate isn't recalculated every time GetHasteRate is called, which is at least once per frame. -Kyz
/** @brief The different game states of ScreenGameplay. */
enum DancingState {
STATE_INTRO = 0, /**< The starting state, pressing Back isn't allowed here. */