2013-12-10 11:26:18 +01:00
|
|
|
#ifndef DANBIAS_CLIENT_GAMESTATE_H
|
|
|
|
#define DANBIAS_CLIENT_GAMESTATE_H
|
2013-12-06 10:38:43 +01:00
|
|
|
#include "GameClientState.h"
|
2013-12-10 11:26:18 +01:00
|
|
|
#include "OysterMath.h"
|
|
|
|
#include <string>
|
2014-02-20 16:35:49 +01:00
|
|
|
#include "GameStateUI.h"
|
2014-02-10 16:30:47 +01:00
|
|
|
|
2014-02-13 15:21:02 +01:00
|
|
|
namespace DanBias { namespace Client
|
2013-12-06 10:38:43 +01:00
|
|
|
{
|
2014-02-12 09:02:44 +01:00
|
|
|
class GameState : public GameClientState
|
2013-12-10 11:26:18 +01:00
|
|
|
{
|
2014-02-13 15:21:02 +01:00
|
|
|
public:
|
2014-02-12 09:02:44 +01:00
|
|
|
enum gameStateState
|
|
|
|
{
|
|
|
|
gameStateState_loading,
|
|
|
|
gameStateState_playing,
|
|
|
|
gameStateState_end,
|
|
|
|
};
|
2014-02-13 15:21:02 +01:00
|
|
|
|
|
|
|
GameState(void);
|
|
|
|
~GameState(void);
|
2014-02-17 11:27:43 +01:00
|
|
|
bool Init( SharedStateContent &shared );
|
|
|
|
GameClientState::ClientState Update( float deltaTime ) override;
|
2014-02-17 16:18:21 +01:00
|
|
|
void InitiatePlayer( int id, const std::string &modelName, const float position[3], const float rotation[4], const float scale[3], bool isMyPlayer );
|
2014-02-17 14:33:11 +01:00
|
|
|
void ReadKeyInput();
|
2014-02-13 15:21:02 +01:00
|
|
|
bool Render()override;
|
|
|
|
bool Release()override;
|
|
|
|
void ChangeState( ClientState next );
|
|
|
|
|
2014-02-18 17:28:24 +01:00
|
|
|
const NetEvent & DataRecieved( const NetEvent &message );
|
2014-02-13 15:21:02 +01:00
|
|
|
|
2014-02-12 09:02:44 +01:00
|
|
|
private:
|
2014-02-12 16:31:15 +01:00
|
|
|
struct MyData;
|
|
|
|
::Utility::DynamicMemory::UniquePointer<MyData> privData;
|
2014-02-21 10:49:02 +01:00
|
|
|
GameStateUI *currGameUI, *gameUI, *respawnUI, *statsUI;
|
2014-02-20 16:35:49 +01:00
|
|
|
|
2014-02-20 16:51:14 +01:00
|
|
|
// DEGUG KEYS
|
|
|
|
bool key_Reload_Shaders;
|
|
|
|
bool key_Wireframe_Toggle;
|
|
|
|
bool renderWhireframe;
|
2014-02-21 10:49:02 +01:00
|
|
|
bool key_showStats;
|
|
|
|
bool renderStats;
|
2014-02-20 16:51:14 +01:00
|
|
|
// !DEGUG KEYS
|
2014-02-21 10:49:02 +01:00
|
|
|
|
2014-02-12 09:02:44 +01:00
|
|
|
};
|
2014-02-13 15:21:02 +01:00
|
|
|
} }
|
2013-12-10 11:26:18 +01:00
|
|
|
#endif
|