2026-03-01 12:16:08 +08:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "Command.h"
|
|
|
|
|
|
|
|
|
|
class TimeCommand : public Command
|
|
|
|
|
{
|
|
|
|
|
public:
|
|
|
|
|
virtual EGameCommand getId();
|
2026-03-03 03:04:10 +08:00
|
|
|
virtual int getPermissionLevel();
|
2026-03-02 17:37:16 +07:00
|
|
|
virtual void execute(shared_ptr<CommandSender> source, byteArray commandData);
|
2026-03-01 12:16:08 +08:00
|
|
|
|
|
|
|
|
protected:
|
2026-03-02 17:37:16 +07:00
|
|
|
void doSetTime(shared_ptr<CommandSender> source, int value);
|
|
|
|
|
void doAddTime(shared_ptr<CommandSender> source, int value);
|
2026-03-01 12:16:08 +08:00
|
|
|
|
|
|
|
|
public:
|
2026-03-02 17:37:16 +07:00
|
|
|
static shared_ptr<GameCommandPacket> preparePacket(bool night);
|
2026-03-01 12:16:08 +08:00
|
|
|
};
|