Ark Server API (ASA) - Wiki
Loading...
Searching...
No Matches
AsaApi::ICommands Class Referenceabstract

#include <ICommands.h>

+ Inheritance diagram for AsaApi::ICommands:

Public Member Functions

virtual ~ICommands ()=default
 
virtual void AddChatCommand (const FString &command, const std::function< void(AShooterPlayerController *, FString *, int, int)> &callback)=0
 Adds a chat command.
 
virtual void AddConsoleCommand (const FString &command, const std::function< void(APlayerController *, FString *, bool)> &callback)=0
 Adds a console command.
 
virtual void AddRconCommand (const FString &command, const std::function< void(RCONClientConnection *, RCONPacket *, UWorld *)> &callback)=0
 Adds a rcon command.
 
virtual void AddOnTickCallback (const FString &id, const std::function< void(float)> &callback)=0
 Added function will be called every frame.
 
virtual void AddOnTimerCallback (const FString &id, const std::function< void()> &callback)=0
 Added function will be called every second.
 
virtual void AddOnChatMessageCallback (const FString &id, const std::function< bool(AShooterPlayerController *, FString *, int, int, bool, bool)> &callback)=0
 Added function will be called for AShooterPlayerController->ServerSendChatMessage events.
 
virtual bool RemoveChatCommand (const FString &command)=0
 Removes a chat command.
 
virtual bool RemoveConsoleCommand (const FString &command)=0
 Removes a console command.
 
virtual bool RemoveRconCommand (const FString &command)=0
 Removes a rcon command.
 
virtual bool RemoveOnTickCallback (const FString &id)=0
 Removes a on-tick callback.
 
virtual bool RemoveOnTimerCallback (const FString &id)=0
 Removes an on-timer callback.
 
virtual bool RemoveOnChatMessageCallback (const FString &id)=0
 Removes an on-chat-message callback.
 

Detailed Description

Definition at line 9 of file ICommands.h.

Constructor & Destructor Documentation

◆ ~ICommands()

virtual AsaApi::ICommands::~ICommands ( )
virtualdefault

Member Function Documentation

◆ AddChatCommand()

virtual void AsaApi::ICommands::AddChatCommand ( const FString & command,
const std::function< void(AShooterPlayerController *, FString *, int, int)> & callback )
pure virtual

Adds a chat command.

Parameters
commandCommand name
callbackCallback function

Implemented in AsaApi::Commands.

◆ AddConsoleCommand()

virtual void AsaApi::ICommands::AddConsoleCommand ( const FString & command,
const std::function< void(APlayerController *, FString *, bool)> & callback )
pure virtual

Adds a console command.

Parameters
commandCommand name
callbackCallback function

Implemented in AsaApi::Commands.

◆ AddOnChatMessageCallback()

virtual void AsaApi::ICommands::AddOnChatMessageCallback ( const FString & id,
const std::function< bool(AShooterPlayerController *, FString *, int, int, bool, bool)> & callback )
pure virtual

Added function will be called for AShooterPlayerController->ServerSendChatMessage events.

Parameters
idUnique ID
callbackCallback function

Implemented in AsaApi::Commands.

◆ AddOnTickCallback()

virtual void AsaApi::ICommands::AddOnTickCallback ( const FString & id,
const std::function< void(float)> & callback )
pure virtual

Added function will be called every frame.

Parameters
idUnique ID
callbackCallback function

Implemented in AsaApi::Commands.

◆ AddOnTimerCallback()

virtual void AsaApi::ICommands::AddOnTimerCallback ( const FString & id,
const std::function< void()> & callback )
pure virtual

Added function will be called every second.

Parameters
idUnique ID
callbackCallback function

Implemented in AsaApi::Commands.

◆ AddRconCommand()

virtual void AsaApi::ICommands::AddRconCommand ( const FString & command,
const std::function< void(RCONClientConnection *, RCONPacket *, UWorld *)> & callback )
pure virtual

Adds a rcon command.

Parameters
commandCommand name
callbackCallback function

Implemented in AsaApi::Commands.

◆ RemoveChatCommand()

virtual bool AsaApi::ICommands::RemoveChatCommand ( const FString & command)
pure virtual

Removes a chat command.

Parameters
commandCommand name
Returns
true if success, false otherwise

Implemented in AsaApi::Commands.

◆ RemoveConsoleCommand()

virtual bool AsaApi::ICommands::RemoveConsoleCommand ( const FString & command)
pure virtual

Removes a console command.

Parameters
commandCommand name
Returns
true if success, false otherwise

Implemented in AsaApi::Commands.

◆ RemoveOnChatMessageCallback()

virtual bool AsaApi::ICommands::RemoveOnChatMessageCallback ( const FString & id)
pure virtual

Removes an on-chat-message callback.

Parameters
idCallback ID
Returns
true if success, false otherwise

Implemented in AsaApi::Commands.

◆ RemoveOnTickCallback()

virtual bool AsaApi::ICommands::RemoveOnTickCallback ( const FString & id)
pure virtual

Removes a on-tick callback.

Parameters
idCallback ID
Returns
true if success, false otherwise

Implemented in AsaApi::Commands.

◆ RemoveOnTimerCallback()

virtual bool AsaApi::ICommands::RemoveOnTimerCallback ( const FString & id)
pure virtual

Removes an on-timer callback.

Parameters
idCallback ID
Returns
true if success, false otherwise

Implemented in AsaApi::Commands.

◆ RemoveRconCommand()

virtual bool AsaApi::ICommands::RemoveRconCommand ( const FString & command)
pure virtual

Removes a rcon command.

Parameters
commandCommand name
Returns
true if success, false otherwise

Implemented in AsaApi::Commands.


The documentation for this class was generated from the following file: