2014-01-28 09:00:02 +01:00
|
|
|
/////////////////////////////////////////////////////////////////////
|
|
|
|
// Created by [Dennis Andersen] [2013]
|
|
|
|
/////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#include "..\GameClient.h"
|
|
|
|
#include <NetworkSession.h>
|
|
|
|
#include <Protocols.h>
|
|
|
|
|
|
|
|
using namespace Utility::DynamicMemory;
|
2014-01-29 10:18:01 +01:00
|
|
|
using namespace Oyster::Network;
|
2014-01-28 09:00:02 +01:00
|
|
|
using namespace DanBias;
|
|
|
|
using namespace GameLogic;
|
|
|
|
|
|
|
|
|
2014-02-18 08:55:38 +01:00
|
|
|
GameClient::GameClient()
|
2014-01-28 09:00:02 +01:00
|
|
|
{
|
2014-02-18 08:55:38 +01:00
|
|
|
this->player = 0;
|
2014-02-04 16:07:10 +01:00
|
|
|
isReady = false;
|
2014-02-18 08:55:38 +01:00
|
|
|
this->character = L"Unknown";
|
|
|
|
this->alias = L"Unknown";
|
|
|
|
this->secondsSinceLastResponse = 0.0f;
|
2014-01-28 09:00:02 +01:00
|
|
|
}
|
|
|
|
GameClient::~GameClient()
|
|
|
|
{
|
|
|
|
this->player = 0;
|
2014-02-18 08:55:38 +01:00
|
|
|
this->isReady = false;
|
|
|
|
this->character = L"Unknown";
|
|
|
|
this->alias = L"Unknown";
|
|
|
|
this->secondsSinceLastResponse = 0.0f;
|
2014-01-28 09:00:02 +01:00
|
|
|
}
|
|
|
|
|
2014-02-18 08:55:38 +01:00
|
|
|
void GameClient::SetPlayer(GameLogic::IPlayerData* player)
|
2014-01-28 09:00:02 +01:00
|
|
|
{
|
2014-02-18 08:55:38 +01:00
|
|
|
this->player = player;
|
2014-01-31 08:41:08 +01:00
|
|
|
}
|
2014-02-04 16:07:10 +01:00
|
|
|
void GameClient::SetReadyState(bool r)
|
|
|
|
{
|
|
|
|
this->isReady = r;
|
|
|
|
}
|
|
|
|
void GameClient::SetSinceLastResponse(float s)
|
|
|
|
{
|
|
|
|
this->secondsSinceLastResponse = s;
|
|
|
|
}
|
2014-02-18 08:55:38 +01:00
|
|
|
void GameClient::SetAlias(std::wstring alias)
|
|
|
|
{
|
|
|
|
this->alias = alias;
|
|
|
|
}
|
|
|
|
void GameClient::SetCharacter(std::wstring character)
|
|
|
|
{
|
|
|
|
this->character = character;
|
|
|
|
}
|
2014-01-31 08:41:08 +01:00
|
|
|
|
|
|
|
|