|
R-Type
Distributed multiplayer game engine in C++
|
Displays available commands to the player. More...
#include <HelpCommand.hpp>


Public Member Functions | |
| HelpCommand (const std::vector< std::shared_ptr< ICommand > > &commands) | |
| ~HelpCommand () override=default | |
| std::string | execute (const std::vector< std::string > &args, const CommandContext &context) override |
| Execute the command. | |
| std::string | getName () const override |
| Get command name. | |
| std::string | getDescription () const override |
| Get command description. | |
| std::string | getUsage () const override |
| Get command usage. | |
Public Member Functions inherited from server::ICommand | |
| virtual | ~ICommand ()=default |
Private Attributes | |
| const std::vector< std::shared_ptr< ICommand > > & | _commands |
Displays available commands to the player.
Usage: /help Lists all registered commands with their descriptions.
Definition at line 24 of file HelpCommand.hpp.
|
inline |
Definition at line 26 of file HelpCommand.hpp.
|
overridedefault |
|
overridevirtual |
Execute the command.
| args | Command arguments (without the command name) |
| context | Execution context with player and room information |
Implements server::ICommand.
Definition at line 13 of file HelpCommand.cpp.
References _commands.
|
inlineoverridevirtual |
Get command description.
Implements server::ICommand.
Definition at line 31 of file HelpCommand.hpp.
|
inlineoverridevirtual |
Get command name.
Implements server::ICommand.
Definition at line 30 of file HelpCommand.hpp.
|
inlineoverridevirtual |
Get command usage.
Implements server::ICommand.
Definition at line 32 of file HelpCommand.hpp.
|
private |
Definition at line 35 of file HelpCommand.hpp.
Referenced by execute().