wavelength 1.0.0
Loading...
Searching...
No Matches
banplayertask.h
Go to the documentation of this file.
1#pragma once
2
3#include <librtmedius.h>
4
5#include "netflow/nettask.h"
6
13class BanPlayerTask : public NetTask {
14public:
21 ~BanPlayerTask() override = default;
22
24 static constexpr int kBanDuration = 60;
25
34 BanPlayerTask(int nWorldId, int nAccountId) : mWorldId(nWorldId), mAccountId(nAccountId) {
35 }
36
47 static void
48 OnResponse(int nConnection, int nType, int nSize, const rtMediusResponse *pResponse);
49
50protected:
57 void OnStart() override;
58
59private:
60 int mWorldId;
61 int mAccountId;
62};
static constexpr int kBanDuration
The length of a ban the request gives.
Definition banplayertask.h:24
BanPlayerTask(int nWorldId, int nAccountId)
Construct a step for a player.
Definition banplayertask.h:34
static void OnResponse(int nConnection, int nType, int nSize, const rtMediusResponse *pResponse)
Ignore the response of the lobby server.
~BanPlayerTask() override=default
Destroy the object.
void OnStart() override
Send the request and finish.
NetTask()
Construct a task outside any NetMultiTask.
Definition nettask.h:24