> 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/interface/cuxial-anuncios/troubleshooting.md).

# Troubleshooting

Common Cuxial Announcements problems, with their cause and fix.

The most frequent problems after installing Cuxial Announcements, with the cause and the fix for each one.

<details>

<summary>The resource does not start</summary>

**Cause.** A dependency is missing or starts later than the script. Cuxial Announcements needs `ox_lib`, `oxmysql` and `cuxial_bridge`.

**Fix.** Start the dependencies first:

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

```cfg
ensure ox_lib
ensure oxmysql
ensure cuxial_bridge
ensure cuxial_anuncios
```

{% endcode %}

</details>

<details>

<summary>/anuncio answers that the job has no announcement style</summary>

The notification reads `Tu trabajo no tiene un estilo de anuncio configurado.`

**Cause.** There is no style for the player's current job, or the style was saved with a different job name. The name is compared exactly, including upper and lower case.

**Fix.** Open the panel and create or edit the style. In the job field write the internal name of the job, for example `police`, not its label.

</details>

<details>

<summary>/crearanuncio answers that you have no permission</summary>

The notification reads `No tienes permisos para usar este comando.`

**Cause.** Your account does not have the permission set in `adminPermission`.

**Fix.** Give your account that permission in your framework, or change `adminPermission` in `shared/config.lua` to one you already have. On ESX the default `'admin'` covers the groups `admin` and `superadmin`.

</details>

<details>

<summary>/anuncio asks the player to wait</summary>

**Cause.** The player sent an announcement less than `cooldown` seconds ago.

**Fix.** None needed. To shorten the wait, lower `cooldown` in `shared/config.lua`.

</details>

<details>

<summary>The announcement shows without logo or background</summary>

**Cause.** The image field holds a file name that is not in the resource, or a link that does not start with `http://` or `https://`.

**Fix.** Put logos in `web/build/images/icons/` and backgrounds in `web/build/images/background/`, write the file name with its extension, and restart the resource. For a link, use the full URL.

</details>

<details>

<summary>The announcement has no sound</summary>

**Cause.** The sound file is not in `web/build/sounds/`, the link is not reachable, or the volume of the style is `0`.

**Fix.** Leave the sound field empty to use the default sound, or check the file name and the volume in the style. The panel has a button to test the sound.

</details>

<details>

<summary>The panel does not open, or announcements never appear</summary>

**Cause.** The interface is not loading. The folder `web/build` is missing or incomplete, usually after a partial upload.

**Fix.** Make sure `web/build/index.html` exists inside the resource. If it does not, copy the resource again from the original package and restart the server.

</details>

<details>

<summary>Styles are lost after a restart, or cannot be saved</summary>

**Cause.** The table `cuxial_anuncios` could not be created or read. The server console shows `[CuxialAnuncios] error al cargar estilos desde la base de datos` or an `oxmysql` error.

**Fix.** Check the `oxmysql` connection and that the database user can create tables. Then restart the resource.

</details>

<details>

<summary>An announcement appears late</summary>

**Cause.** Announcements are queued. Each one waits for the previous one to finish.

**Fix.** None needed. To shorten the queue, lower `duration` or raise `cooldown`.

</details>


---

# 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/interface/cuxial-anuncios/troubleshooting.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.
