mirror of
https://github.com/HikikoMarmy/Champions-Reborn-Server.git
synced 2026-04-04 16:49:47 -03:00
36 lines
746 B
C++
36 lines
746 B
C++
#pragma once
|
|
|
|
#include <memory>
|
|
#include <string>
|
|
|
|
#include "../GenericNetRequest.hpp"
|
|
#include "../GenericNetResponse.hpp"
|
|
|
|
class RequestStartGame : public GenericRequest
|
|
{
|
|
private:
|
|
std::vector< uint8_t > m_data;
|
|
|
|
enum ERROR_CODE {
|
|
SUCCESS = 0,
|
|
FATAL_ERROR,
|
|
GENERAL_ERROR,
|
|
};
|
|
public:
|
|
static std::unique_ptr< RequestStartGame > Create()
|
|
{
|
|
return std::make_unique< RequestStartGame >();
|
|
}
|
|
|
|
sptr_generic_response ProcessRequest( sptr_socket socket, sptr_byte_stream stream ) override;
|
|
void Deserialize( sptr_byte_stream stream ) override;
|
|
};
|
|
|
|
class ResultStartGame : public GenericResponse {
|
|
private:
|
|
int32_t m_reply;
|
|
|
|
public:
|
|
ResultStartGame( GenericRequest *request, int32_t reply );
|
|
void Serialize( ByteBuffer &out ) const;
|
|
}; |