R-Type
Distributed multiplayer game engine in C++
Loading...
Searching...
No Matches
KickCommand.hpp
Go to the documentation of this file.
1/*
2** EPITECH PROJECT, 2025
3** Created on 14/01/2026.
4** File description:
5** KickCommand.hpp
6*/
7
8#pragma once
9
10#include <string>
11#include <vector>
12#include "ICommand.hpp"
13
14namespace server {
15
25 class KickCommand : public ICommand {
26 public:
27 KickCommand() = default;
28 ~KickCommand() override = default;
29
30 std::string execute(const std::vector<std::string> &args, const CommandContext &context) override;
31 std::string getName() const override { return "kick"; }
32 std::string getDescription() const override { return "Kick a player from the room"; }
33 std::string getUsage() const override { return "/kick <player_id>"; }
34 };
35
36} // namespace server
Interface for all chat commands.
Definition ICommand.hpp:23
Kicks a player from the current room.
std::string getUsage() const override
Get command usage.
~KickCommand() override=default
std::string getName() const override
Get command name.
std::string getDescription() const override
Get command description.
std::string execute(const std::vector< std::string > &args, const CommandContext &context) override
Execute the command.
Context information for command execution.