SBSPSS/source/frontend/frontend.h

107 lines
2.0 KiB
C
Raw Normal View History

2000-11-13 20:38:51 +01:00
/*=========================================================================
frontend.h
Author: PKG
Created:
Project: Spongebob
Purpose:
Copyright (c) 2000 Climax Development Ltd
===========================================================================*/
#ifndef __FRONTEND_FRONTENTD_H__
2000-11-20 16:45:17 +01:00
#define __FRONTEND_FRONTENTD_H__
2000-11-13 20:38:51 +01:00
/*----------------------------------------------------------------------
Includes
-------- */
#ifndef __SYSTEM_GSTATE_H__
#include "system\gstate.h"
#endif
/* Std Lib
------- */
/*----------------------------------------------------------------------
Tyepdefs && Defines
------------------- */
2000-11-20 16:45:17 +01:00
typedef enum
{
EXITCODE__NONE,
EXITCODE__START_GAME,
EXITCODE__GOTO_OPTIONS,
} MainTitleExitCode;
2000-11-13 20:38:51 +01:00
/*----------------------------------------------------------------------
Structure defintions
-------------------- */
class CFrontEndScene : public CScene
{
public:
2000-11-20 16:45:17 +01:00
typedef enum
{
MODE__MAIN_TITLES,
MODE__GAME_OPTIONS,
MODE__CHOOSE_SLOT,
MODE__DEMO,
MODE__NONE,
} FrontEndMode;
2000-11-13 20:38:51 +01:00
void init();
void shutdown();
void render();
void think(int _frames);
int readyToShutdown();
2000-11-20 18:28:21 +01:00
char *getSceneName() {return"FrontEnd";}
2000-11-13 20:38:51 +01:00
private:
2000-11-20 16:45:17 +01:00
void setMode(FrontEndMode _newMode);
FrontEndMode m_mode;
class CFrontEndMode *m_modeCode;
static class CFrontEndMode *s_modeCodes[];
};
class CFrontEndMode
{
public:
virtual void init()=0;
virtual void shutdown()=0;
virtual void render()=0;
virtual void think(int _frames)=0;
virtual int isReadyToExit()=0;
virtual CFrontEndScene::FrontEndMode getNextMode()=0;
2000-11-13 20:38:51 +01:00
};
/*----------------------------------------------------------------------
Globals
------- */
/*----------------------------------------------------------------------
Functions
--------- */
extern CFrontEndScene FrontEndScene;
/*---------------------------------------------------------------------- */
#endif /* __FRONTEND_FRONTENTD_H__ */
/*===========================================================================
end */