Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members

ScreenSelectDifficulty.h

Go to the documentation of this file.
00001 #ifndef ScreenSelectDifficulty_H 00002 #define ScreenSelectDifficulty_H 00003 00004 #include "ScreenSelect.h" 00005 #include "Sprite.h" 00006 #include "BitmapText.h" 00007 #include "RageSound.h" 00008 #include "RandomSample.h" 00009 00010 #define MAX_CHOICES_PER_PAGE 15 00011 00012 class ScreenSelectDifficulty : public ScreenSelect 00013 { 00014 public: 00015 ScreenSelectDifficulty( CString sName ); 00016 00017 virtual void Update( float fDelta ); 00018 00019 virtual void MenuLeft( PlayerNumber pn ); 00020 virtual void MenuRight( PlayerNumber pn ); 00021 virtual void MenuUp( PlayerNumber pn ) {}; 00022 virtual void MenuDown( PlayerNumber pn ) {}; 00023 virtual void MenuStart( PlayerNumber pn ); 00024 // virtual void MenuBack( PlayerNumber pn ); 00025 virtual void TweenOffScreen(); 00026 virtual void TweenOnScreen(); 00027 00028 virtual void HandleScreenMessage( const ScreenMessage SM ); 00029 00030 protected: 00031 enum Page { PAGE_1, PAGE_2, NUM_PAGES }; 00032 00033 virtual int GetSelectionIndex( PlayerNumber pn ); 00034 virtual void UpdateSelectableChoices(); 00035 00036 float GetCursorX( PlayerNumber pn ); 00037 float GetCursorY( PlayerNumber pn ); 00038 bool ChangeWithinPage( PlayerNumber pn, int iNewChoice, bool bChangingPages ); 00039 void ChangePage( Page newPage ); 00040 00041 ActorFrame m_framePages; // to hold the 2 pages 00042 00043 Sprite m_sprInfo[NUM_PAGES][MAX_CHOICES_PER_PAGE]; 00044 Sprite m_sprPicture[NUM_PAGES][MAX_CHOICES_PER_PAGE]; 00045 Sprite m_sprExplanation[NUM_PAGES]; 00046 Sprite m_sprMore[NUM_PAGES]; 00047 00048 Sprite m_sprCursor[NUM_PLAYERS]; 00049 Sprite m_sprShadow[NUM_PLAYERS]; 00050 Sprite m_sprOK[NUM_PLAYERS]; 00051 00052 RageSound m_soundChange; 00053 RandomSample m_soundDifficult; 00054 00055 vector<GameCommand> m_GameCommands[NUM_PAGES]; 00056 00057 Page m_CurrentPage; 00058 int m_iChoiceOnPage[NUM_PLAYERS]; 00059 bool m_bChosen[NUM_PLAYERS]; 00060 00061 float m_fLockInputTime; 00062 }; 00063 00064 #endif 00065 00066 /* 00067 * (c) 2001-2004 Chris Danford 00068 * All rights reserved. 00069 * 00070 * Permission is hereby granted, free of charge, to any person obtaining a 00071 * copy of this software and associated documentation files (the 00072 * "Software"), to deal in the Software without restriction, including 00073 * without limitation the rights to use, copy, modify, merge, publish, 00074 * distribute, and/or sell copies of the Software, and to permit persons to 00075 * whom the Software is furnished to do so, provided that the above 00076 * copyright notice(s) and this permission notice appear in all copies of 00077 * the Software and that both the above copyright notice(s) and this 00078 * permission notice appear in supporting documentation. 00079 * 00080 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 00081 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 00082 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF 00083 * THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS 00084 * INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT 00085 * OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS 00086 * OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR 00087 * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 00088 * PERFORMANCE OF THIS SOFTWARE. 00089 */

Generated on Thu Jan 27 20:57:32 2005 for StepMania by doxygen 1.3.7