mirror of
https://github.com/4jcraft/4jcraft.git
synced 2026-04-24 06:03:37 +00:00
26 lines
696 B
C++
26 lines
696 B
C++
#pragma once
|
|
|
|
#include <stdint.h>
|
|
|
|
#include <memory>
|
|
|
|
#include "minecraft/commands/Command.h"
|
|
#include "minecraft/commands/CommandsEnum.h"
|
|
#include "minecraft/network/packet/GameCommandPacket.h"
|
|
|
|
class CommandSender;
|
|
|
|
class TimeCommand : public Command {
|
|
public:
|
|
virtual EGameCommand getId();
|
|
virtual int getPermissionLevel();
|
|
virtual void execute(std::shared_ptr<CommandSender> source,
|
|
std::vector<uint8_t>& commandData);
|
|
|
|
protected:
|
|
void doSetTime(std::shared_ptr<CommandSender> source, int value);
|
|
void doAddTime(std::shared_ptr<CommandSender> source, int value);
|
|
|
|
public:
|
|
static std::shared_ptr<GameCommandPacket> preparePacket(bool night);
|
|
}; |