mirror of
https://github.com/HikikoMarmy/Champions-Reborn-Server.git
synced 2026-04-04 16:49:47 -03:00
Reorganized and cleaned up the solution.
This commit is contained in:
29
Include/Network/Event/RequestGetServerAddress.hpp
Normal file
29
Include/Network/Event/RequestGetServerAddress.hpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#pragma once
|
||||
|
||||
#include <memory>
|
||||
#include <string>
|
||||
|
||||
#include "../GenericNetRequest.hpp"
|
||||
#include "../GenericNetResponse.hpp"
|
||||
#include "Common/Constant.hpp"
|
||||
|
||||
class RequestGetServerAddress : public GenericRequest {
|
||||
public:
|
||||
static std::unique_ptr< RequestGetServerAddress > Create()
|
||||
{
|
||||
return std::make_unique< RequestGetServerAddress >();
|
||||
}
|
||||
|
||||
sptr_generic_response ProcessRequest( sptr_socket socket, sptr_byte_stream stream ) override;
|
||||
void Deserialize( sptr_byte_stream stream ) override;
|
||||
};
|
||||
|
||||
class ResultGetServerAddress : public GenericResponse {
|
||||
public:
|
||||
std::string m_ip;
|
||||
int32_t m_port;
|
||||
RealmGameType m_gameType;
|
||||
|
||||
ResultGetServerAddress( GenericRequest *request, std::string ip, int32_t port, RealmGameType clientType );
|
||||
void Serialize( ByteBuffer &out ) const;
|
||||
};
|
||||
Reference in New Issue
Block a user