Files
wagic/projects/mtg/include/GameStateMenu.h
wagic.jeck 4b8d344bcd Jeck - Card ID collisions, cache fixes, cache deleted pooling.
* mtgid now defaults to 0.
 * TextScroller will not update when empty.
 * Cache now moves WCachedResources we're finished with to a garbage pool for later use (to reduce memory fragmentation). 
 * Demo still crashes... but I'm thinking that has to do with fragmentation, not a leak?
2009-09-19 01:48:42 +00:00

60 lines
1.4 KiB
C++

#ifndef _GAME_STATE_MENU_H_
#define _GAME_STATE_MENU_H_
#include <JGui.h>
#include <dirent.h>
#include "../include/GameState.h"
#include "../include/SimpleMenu.h"
#include "../include/TextScroller.h"
class GameStateMenu: public GameState, public JGuiListener
{
private:
TextScroller * scroller;
int scrollerSet;
JGuiController* mGuiController;
SimpleMenu* subMenuController;
SimpleMenu* gameTypeMenu;
int hasChosenGameType;
JQuad * mIcons[10];
JTexture * bgTexture;
JTexture * movingWTexture;
JQuad * mBg;
JQuad * mSplash;
JQuad * mMovingW;
float mCreditsYPos;
int currentState;
//JMusic * bgMusic;
int mVolume;
char nbcardsStr[400];
DIR *mDip;
struct dirent *mDit;
char mCurrentSetName[32];
char mCurrentSetFileName[512];
int mReadConf;
float timeIndex;
float angleMultiplier;
float angleW;
float yW;
void fillScroller();
public:
GameStateMenu(GameApp* parent);
virtual ~GameStateMenu();
virtual void Create();
virtual void Destroy();
virtual void Start();
virtual void End();
virtual void Update(float dt);
virtual void Render();
virtual void ButtonPressed(int controllerId, int controlId);
int nextDirectory(const char * root, const char * file); // Retrieves the next directory to have matching file
void resetDirectory();
void createUsersFirstDeck(int setId);
virtual ostream& toString(ostream& out) const;
};
#endif