Refactoring. Client and server has Update Loop that runs before any game logic each frame.

This commit is contained in:
stiffly
2015-12-15 14:53:56 +01:00
parent 0a8a9e5099
commit 478c692315
8 changed files with 88 additions and 57 deletions
+4
View File
@@ -25,6 +25,7 @@ public:
Client();
~Client();
void Start(World* world, EventBroker* eventBroker);
void Update();
void Close();
private:
void ReadFromServer();
@@ -56,6 +57,9 @@ private:
unsigned int m_PreviousPacketID = 0;
unsigned int m_SendPacketID = 0;
// Game Logic
std::vector<unsigned int> m_PlayersToCreate;
World* m_World;
int m_PlayerID = -1;
glm::vec2 m_PlayerPositions[MAXCONNECTIONS];