2023-07-02 00:59:02 +02:00
|
|
|
# Table: command
|
|
|
|
|
|
|
|
Table for calling menu commands.
|
|
|
|
|
|
|
|
## Functions (2)
|
|
|
|
|
|
|
|
### `call(command_name, _args)`
|
|
|
|
|
|
|
|
Call a menu command.
|
|
|
|
|
|
|
|
- **Parameters:**
|
|
|
|
- `command_name` (string): The name of the command that will be called.
|
|
|
|
- `_args` (table): Optional. List of arguments for the command.
|
|
|
|
|
2023-07-05 00:30:57 +02:00
|
|
|
**Example Usage:**
|
2023-07-02 00:59:02 +02:00
|
|
|
```lua
|
|
|
|
command.call(command_name, _args)
|
|
|
|
```
|
|
|
|
|
|
|
|
### `call_player(player_idx, command_name, _args)`
|
|
|
|
|
|
|
|
Call a menu command on a given player.
|
|
|
|
|
|
|
|
- **Parameters:**
|
|
|
|
- `player_idx` (integer): Index of the player on which the menu command will be executed.
|
|
|
|
- `command_name` (string): The name of the command that will be called.
|
|
|
|
- `_args` (table): Optional. List of arguments for the command.
|
|
|
|
|
2023-07-05 00:30:57 +02:00
|
|
|
**Example Usage:**
|
2023-07-02 00:59:02 +02:00
|
|
|
```lua
|
|
|
|
command.call_player(player_idx, command_name, _args)
|
|
|
|
```
|
|
|
|
|
|
|
|
|