ClearCommand
This function was added in DSL 1
Description
Unregister a command
from the current script. Nothing will happen if the command is not registered with the script, and no error will be raised.
function ClearCommand(command) --[[ ... ]] end
Parameters
command
:string
- The name of the command to unregister. This should be the same name used when registering the command withRegisterCommand
.
Return Values
None.
Example
ClearCommand("my_custom_command")
See Also
- DSL
DoesCommandExist
- To check if a command is registered before attempting to clear it.SetCommand
- To register a command that can be executed in the script.