|
|
|
@ -2,6 +2,8 @@
|
|
|
|
|
|
|
|
|
|
#include "MinecraftClient.h" |
|
|
|
|
#include "ServerStatus.h" |
|
|
|
|
#include "config/ServerProperties.h" |
|
|
|
|
|
|
|
|
|
#include "protocol/Protocol.h" |
|
|
|
|
#include "PacketReader.h" |
|
|
|
|
//#include "JobManager.h"
|
|
|
|
@ -10,15 +12,12 @@
|
|
|
|
|
|
|
|
|
|
#include "network/IListenerInterface.h" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
namespace Feather |
|
|
|
|
{ |
|
|
|
|
class ServerProperties; |
|
|
|
|
|
|
|
|
|
class DedicatedServer final : public Network::IListenerInterface |
|
|
|
|
{ |
|
|
|
|
public: |
|
|
|
|
DedicatedServer(ServerProperties* properties); |
|
|
|
|
DedicatedServer(Config::ServerProperties* properties); |
|
|
|
|
~DedicatedServer(); |
|
|
|
|
|
|
|
|
|
void OnClientConnect(Network::TCPClientHandle&& client) override; |
|
|
|
@ -32,7 +31,7 @@ namespace Feather
|
|
|
|
|
void HandleUnknownPacket(MinecraftClient& client, int32_t id, const PacketReader& packet); |
|
|
|
|
|
|
|
|
|
private: |
|
|
|
|
ServerProperties* m_properties; |
|
|
|
|
Config::ServerProperties* m_properties; |
|
|
|
|
Network::TCPListener m_listener; |
|
|
|
|
ServerStatus m_status; |
|
|
|
|
|
|
|
|
|