consoleCommand: Difference between revisions
Jump to navigation
Jump to search
m (Mex moved page ConsoleCommand to consoleCommand) |
No edit summary |
||
Line 8: | Line 8: | ||
|return1 = void | |return1 = void | ||
|returnFail1 = void | |returnFail1 = void | ||
|notes = This is not an alternative to triggering [[addCommandHandler|command handlers]] or the [[OnPlayerCommand|command event]]. This is only for calling a command in the server or client console<br> | |||
For security purposes, the client side of this function is only available when '''not''' connected to a server | |||
}} | }} |
Latest revision as of 23:46, 21 August 2025
Function
Server and Client
Online and Offline
Available since Server 1.0.0, Client 1.0.0
void consoleCommand(string commandWithParameters)
The consoleCommand function is used to emulate typing a command manually into the console.
Parameters
1) | string | commandWithParameters | A string containing a command with parameters. |
Return
void | This function doesn't return a value. |
Notes
- This is not an alternative to triggering command handlers or the command event. This is only for calling a command in the server or client console.
- For security purposes, the client side of this function is only available when not connected to a server.
Examples
There aren't any examples for this function.
Compatibility
There isn't any compatibility information for this function.
Related
Server Related
addCommandHandler
consoleCommand
hasCommandHandler
removeCommandHandler
Client Related
addCommandHandler
consoleCommand
hasCommandHandler
removeCommandHandler