Danbias/Code/Game/GameServer/Implementation/GameLobby.cpp

54 lines
1.3 KiB
C++
Raw Normal View History

2014-01-28 09:00:02 +01:00
/////////////////////////////////////////////////////////////////////
// Created by [Dennis Andersen] [2013]
/////////////////////////////////////////////////////////////////////
#include "..\GameLobby.h"
#include <PlayerProtocols.h>
#include <PostBox\PostBox.h>
using namespace Utility::DynamicMemory;
using namespace Oyster::Network;
using namespace Oyster;
namespace DanBias
{
GameLobby::GameLobby()
{ }
GameLobby::~GameLobby()
{ }
void GameLobby::Release()
2014-01-29 10:18:01 +01:00
{
NetworkSession::CloseSession(true);
2014-01-28 09:00:02 +01:00
}
2014-01-29 10:18:01 +01:00
void GameLobby::Update()
2014-01-28 09:00:02 +01:00
{
2014-01-29 10:18:01 +01:00
this->ProcessClients();
2014-01-28 09:00:02 +01:00
}
2014-01-29 10:18:01 +01:00
GameLobby::operator bool()
2014-01-28 09:00:02 +01:00
{
2014-01-29 10:18:01 +01:00
return true;
2014-01-28 09:00:02 +01:00
}
2014-01-29 10:18:01 +01:00
void GameLobby::ClientEventCallback(NetEvent<NetworkClient*, NetworkClient::ClientEventArgs> e)
{
switch (e.args.type)
{
case NetworkClient::ClientEventArgs::EventType_Disconnect:
break;
case NetworkClient::ClientEventArgs::EventType_ProtocolFailedToRecieve:
break;
case NetworkClient::ClientEventArgs::EventType_ProtocolFailedToSend:
break;
case NetworkClient::ClientEventArgs::EventType_ProtocolRecieved:
this->ParseProtocol(e.args.data.protocol, e.sender);
break;
}
}
void GameLobby::ClientConnectedEvent(Utility::DynamicMemory::SmartPointer<Oyster::Network::NetworkClient> client)
2014-01-28 09:00:02 +01:00
{
2014-01-29 10:18:01 +01:00
//Attach(client);
2014-01-28 09:00:02 +01:00
}
}//End namespace DanBias