diff --git a/stepmania/src/Song.cpp b/stepmania/src/Song.cpp index 317601c2be..6d41d0edc6 100644 --- a/stepmania/src/Song.cpp +++ b/stepmania/src/Song.cpp @@ -23,6 +23,8 @@ #include "SongCacheIndex.h" #include "GameManager.h" #include "PrefsManager.h" +#include "StyleDef.h" +#include "Notes.h" #include "NotesLoaderSM.h" #include "NotesLoaderDWI.h" @@ -958,3 +960,20 @@ bool Song::RouletteDisplayed() const if(!PREFSMAN->m_bHiddenSongs) return true; return m_SelectionDisplay != SHOW_NEVER; } + +bool Song::HasMusic() const {return m_sMusicFile != "" && IsAFile(GetMusicPath()); }; +bool Song::HasBanner() const {return m_sBannerFile != "" && IsAFile(GetBannerPath()); }; +bool Song::HasBackground() const {return m_sBackgroundFile != "" && IsAFile(GetBackgroundPath()); }; +bool Song::HasCDTitle() const {return m_sCDTitleFile != "" && IsAFile(GetCDTitlePath()); }; +bool Song::HasMovieBackground() const {return m_sMovieBackgroundFile != ""&& IsAFile(GetMovieBackgroundPath()); }; +bool Song::HasBGChanges() const {return m_BackgroundChanges.GetSize() > 0; }; + +int Song::GetNumTimesPlayed() const +{ + int iTotalNumTimesPlayed = 0; + for( int i=0; im_iNumTimesPlayed; + } + return iTotalNumTimesPlayed; +} diff --git a/stepmania/src/ThemeManager.h b/stepmania/src/ThemeManager.h index 52d1586fcf..39e1b14c23 100644 --- a/stepmania/src/ThemeManager.h +++ b/stepmania/src/ThemeManager.h @@ -13,8 +13,8 @@ #include "RageUtil.h" #include "D3DX8Math.h" // for D3DXCOLOR -class IniFile; +class IniFile; class ThemeManager { diff --git a/stepmania/src/song.h b/stepmania/src/song.h index 990622954e..b2969e5030 100644 --- a/stepmania/src/song.h +++ b/stepmania/src/song.h @@ -10,11 +10,11 @@ ----------------------------------------------------------------------------- */ -#include "Notes.h" - #include "GameConstantsAndTypes.h" -#include "RageUtil.h" -#include "StyleDef.h" +#include "Grade.h" + +struct Notes; +class StyleDef; extern const int FILE_CACHE_VERSION; @@ -117,12 +117,12 @@ public: CString GetMovieBackgroundPath() const {return m_sSongDir+m_sMovieBackgroundFile; }; - bool HasMusic() const {return m_sMusicFile != "" && IsAFile(GetMusicPath()); }; - bool HasBanner() const {return m_sBannerFile != "" && IsAFile(GetBannerPath()); }; - bool HasBackground() const {return m_sBackgroundFile != "" && IsAFile(GetBackgroundPath()); }; - bool HasCDTitle() const {return m_sCDTitleFile != "" && IsAFile(GetCDTitlePath()); }; - bool HasMovieBackground() const {return m_sMovieBackgroundFile != ""&& IsAFile(GetMovieBackgroundPath()); }; - bool HasBGChanges() const {return m_BackgroundChanges.GetSize() > 0; }; + bool HasMusic() const; + bool HasBanner() const; + bool HasBackground() const; + bool HasCDTitle() const; + bool HasMovieBackground() const; + bool HasBGChanges() const; CArray m_BPMSegments; // this must be sorted before gameplay CArray m_StopSegments; // this must be sorted before gameplay @@ -175,15 +175,7 @@ public: bool SongHasNotesType( NotesType nt ) const; bool SongHasNotesTypeAndDifficulty( NotesType nt, DifficultyClass dc ) const; void GetNotesThatMatch( const StyleDef *s, int p, CArray& arrayAddTo ) const; - int GetNumTimesPlayed() const - { - int iTotalNumTimesPlayed = 0; - for( int i=0; im_iNumTimesPlayed; - } - return iTotalNumTimesPlayed; - } + int GetNumTimesPlayed() const; bool IsNew() const; bool IsEasy( NotesType nt ) const; Grade GetGradeForDifficultyClass( const StyleDef *s, int p, DifficultyClass dc ) const;