X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;ds=sidebyside;f=src%2Fnet%2FServer.hpp;fp=src%2Fnet%2FServer.hpp;h=0000000000000000000000000000000000000000;hb=8ae45b6555d55f301f83daf8c1337d332d8305ab;hp=a6d509b6974052855e2272574bf8c13a1db7fa9f;hpb=7fd76e64de47f564117b9e6f73f1482d93842108;p=blank.git diff --git a/src/net/Server.hpp b/src/net/Server.hpp deleted file mode 100644 index a6d509b..0000000 --- a/src/net/Server.hpp +++ /dev/null @@ -1,49 +0,0 @@ -#ifndef BLANK_NET_SERVER_HPP -#define BLANK_NET_SERVER_HPP - -#include -#include - - -namespace blank { - -class ClientConnection; -class World; - -class Server { - -public: - struct Config { - Uint16 port = 12354; - }; - -public: - Server(const Config &, World &); - ~Server(); - - void Handle(); - - void Update(int dt); - - UDPsocket &GetSocket() noexcept { return serv_sock; } - UDPpacket &GetPacket() noexcept { return serv_pack; } - - World &GetWorld() noexcept { return world; } - -private: - void HandlePacket(const UDPpacket &); - - ClientConnection &GetClient(const IPaddress &); - -private: - UDPsocket serv_sock; - UDPpacket serv_pack; - std::list clients; - - World &world; - -}; - -} - -#endif