Added and tested the network queue in the server
This is a reimplementation of the old network queue, but using a class. This still uses a separate thread, so that packets can wait if there's any lag. Really, thinking about it, I wonder how necessary this was. On the upside, no singletons this time. Which means that you can have several instances of UDPNetworkManager. That's unintentional, but good to know.
This commit is contained in:
@@ -23,6 +23,7 @@
|
||||
#define SERVERAPPLICATION_HPP_
|
||||
|
||||
#include "udp_network_utility.hpp"
|
||||
#include "network_queue.hpp"
|
||||
|
||||
#include "sqlite3/sqlite3.h"
|
||||
#include "SDL/SDL.h"
|
||||
@@ -52,6 +53,7 @@ private:
|
||||
sqlite3* database = nullptr;
|
||||
|
||||
UDPNetworkUtility networkUtil;
|
||||
NetworkQueue networkQueue;
|
||||
std::list<ClientEntry> clientEntries;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user