WIP trying to get Eventsystem to work in client.

This commit is contained in:
stiffly
2015-12-08 16:13:53 +01:00
parent 8f55e90d2d
commit e92119c99e
4 changed files with 35 additions and 11 deletions
+8 -1
View File
@@ -10,6 +10,8 @@
#include "Network/MessageType.h"
#include "Network/NetworkDefines.h"
#include "Core/EventBroker.h"
#include "Core/EKeyDown.h"
class Client
@@ -17,7 +19,7 @@ class Client
public:
Client();
~Client();
void Start();
void Start(EventBroker* eventBroker);
void Close();
private:
@@ -54,6 +56,11 @@ private:
bool m_ShouldDrawGameBoard = true;
std::string m_PlayerName;
bool m_ThreadIsRunning = true;
// Events
EventBroker* m_EventBroker;
EventRelay<Client, Events::KeyDown> m_EKeyDown;
bool OnKeyDown(const Events::KeyDown &e);
};
#endif