iw7-mod/src/client/game/demonware/servers/service_server.hpp

25 lines
410 B
C++
Raw Normal View History

2022-05-19 19:11:05 +03:00
#pragma once
#include "../reply.hpp"
namespace demonware
{
class service_server
{
public:
virtual ~service_server() = default;
2024-01-31 20:00:28 +02:00
virtual remote_reply create_message(uint8_t type)
2022-05-19 19:11:05 +03:00
{
2024-01-31 20:00:28 +02:00
return remote_reply{ this, type };
2022-05-19 19:11:05 +03:00
}
2024-01-31 20:00:28 +02:00
virtual service_reply create_reply(uint8_t type, uint32_t error = 0)
2022-05-19 19:11:05 +03:00
{
2024-01-31 20:00:28 +02:00
return service_reply{ this, type, error };
2022-05-19 19:11:05 +03:00
}
virtual void send_reply(reply* data) = 0;
};
}