Styles are totally immutable.

This commit is contained in:
Steve Checkoway
2006-12-05 21:00:28 +00:00
parent fa74b9fdcc
commit 46c8af6059
+15 -15
View File
@@ -19,22 +19,22 @@ struct lua_State;
class Style class Style
{ {
public: public:
const Game* m_pGame; // Which Game is this Style used with? const Game *const m_pGame; // Which Game is this Style used with?
bool m_bUsedForGameplay; // Can be used only for gameplay? const bool m_bUsedForGameplay; // Can be used only for gameplay?
bool m_bUsedForEdit; // Can be used for editing? const bool m_bUsedForEdit; // Can be used for editing?
bool m_bUsedForDemonstration; // Can be used for demonstration? const bool m_bUsedForDemonstration; // Can be used for demonstration?
bool m_bUsedForHowToPlay; // Can be used for HowToPlay? const bool m_bUsedForHowToPlay; // Can be used for HowToPlay?
/* The name of the style. (This is currently unused.) */ /* The name of the style. (This is currently unused.) */
const char *m_szName; const char *const m_szName;
/* Steps format used for each player. For example, "dance versus" reads /* Steps format used for each player. For example, "dance versus" reads
* the Steps with the tag "dance-single". */ * the Steps with the tag "dance-single". */
StepsType m_StepsType; const StepsType m_StepsType;
StyleType m_StyleType; const StyleType m_StyleType;
int m_iColsPerPlayer; // number of total tracks this style expects (e.g. 4 for versus, but 8 for double) const int m_iColsPerPlayer; // number of total tracks this style expects (e.g. 4 for versus, but 8 for double)
struct ColumnInfo struct ColumnInfo
{ {
int track; // take note data from this track int track; // take note data from this track
@@ -42,16 +42,16 @@ public:
const char *pzName; // name of this column, or NULL to use the name of a button mapped to it const char *pzName; // name of this column, or NULL to use the name of a button mapped to it
}; };
ColumnInfo m_ColumnInfo[NUM_PLAYERS][MAX_COLS_PER_PLAYER]; // maps each players' column to a track in the NoteData const ColumnInfo m_ColumnInfo[NUM_PLAYERS][MAX_COLS_PER_PLAYER]; // maps each players' column to a track in the NoteData
/* This maps from game inputs to columns. More than one button may map to a /* This maps from game inputs to columns. More than one button may map to a
* single column. */ * single column. */
enum { NO_MAPPING = -1, END_MAPPING = -2 }; enum { NO_MAPPING = -1, END_MAPPING = -2 };
int m_iInputColumn[NUM_GameController][NUM_GameButton]; // maps each input to a column, or GameButton_Invalid const int m_iInputColumn[NUM_GameController][NUM_GameButton]; // maps each input to a column, or GameButton_Invalid
int m_iColumnDrawOrder[MAX_COLS_PER_PLAYER]; const int m_iColumnDrawOrder[MAX_COLS_PER_PLAYER];
bool m_bNeedsZoomOutWith2Players; const bool m_bNeedsZoomOutWith2Players;
bool m_bCanUseBeginnerHelper; const bool m_bCanUseBeginnerHelper;
bool m_bLockDifficulties; // used in couple Styles const bool m_bLockDifficulties; // used in couple Styles
GameInput StyleInputToGameInput( int iCol, PlayerNumber pn ) const; GameInput StyleInputToGameInput( int iCol, PlayerNumber pn ) const;
int GameInputToColumn( const GameInput &GameI ) const; int GameInputToColumn( const GameInput &GameI ) const;