> For the complete documentation index, see [llms.txt](https://docs.cuxial.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cuxial.com/scripts/es/nucleo/cuxial-multichar/commands.md).

# Comandos y permisos

Comandos de Cuxial Multichar, quién puede usarlos y cómo funcionan los permisos de staff.

El nombre de cada comando se puede cambiar en `shared/config.lua`. Estos son los valores por defecto.

## Comandos

| Comando                            | Quién                                                       | Qué hace                                                                                                                                     |
| ---------------------------------- | ----------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
| `/logout`                          | Staff (`group.admin`)                                       | Te devuelve a la selección de personaje                                                                                                      |
| `/logoutplayer [id]`               | Staff (`group.admin`) y consola del servidor                | Manda a otro jugador a la selección de personaje. `id` es el ID de servidor del jugador                                                      |
| `/partnerinvite [target] [type]`   | Todos                                                       | Invita a un jugador cercano a aparecer contigo en la selección. `target` es su ID de servidor. `type` es `cp` (pareja) o `bff` (mejor amigo) |
| `/forcepartner [citizenid] [type]` | Staff (`group.admin`)                                       | Fija tu pareja por citizenid, sin invitación. Mismos valores de `type`                                                                       |
| `/height`                          | Personajes menores con el crecimiento activado por el staff | Abre el panel de estatura                                                                                                                    |

{% hint style="info" %}
`/partnerinvite` necesita que el otro jugador esté a menos de 10 metros, y tiene 60 segundos para responder. Un jugador puede enviar 3 invitaciones por minuto. Los tres valores están en el bloque `partner` del config. Con `partner.enabled = false`, `/partnerinvite` y `/forcepartner` no existen.
{% endhint %}

### Comando opcional

`vehicles.spotCommand` viene desactivado. Si le pones un nombre, el comando copia tu posición actual como `vec4` al portapapeles. Sirve para rellenar `data/vehicle_locations.lua`.

{% code title="shared/config.lua" %}

```lua
vehicles = {
    enabled = true,
    resource = "cuxial_garages",
    spotCommand = "mcspot",
},
```

{% endcode %}

## Teclas

Cuxial Multichar no registra ninguna tecla.

## Permisos

Los comandos de staff usan el campo `restricted` de cada comando. Es un grupo ACE, y lo comprueba `ox_lib`. El permiso de `/forcepartner` está en `partner.commands.force`.

{% code title="shared/config.lua" %}

```lua
commands = {
    logout = { name = "logout", restricted = "group.admin" },
    logoutPlayer = { name = "logoutplayer", restricted = "group.admin" },
},
```

{% endcode %}

Para dar ese grupo a un jugador:

{% code title="server.cfg" %}

```cfg
add_principal identifier.license:xxxxxxxxxxxxxxxx group.admin
```

{% endcode %}

Pon `restricted = false` para abrir un comando a todos los jugadores.

{% hint style="warning" %}
Los exports que aprueban personajes menores no comprueban permisos. Tiene que hacerlo el recurso que los llama. Mira [Exports y eventos](/scripts/es/nucleo/cuxial-multichar/developers.md).
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.cuxial.com/scripts/es/nucleo/cuxial-multichar/commands.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
