# faq

Answers to the most common questions about moh-boombox.

<details>

<summary>Can I use this without a target system?</summary>

Yes. Set `Config.TargetSystem = 'none'`. Boomboxes will still be placed and play audio, but players will have no interact or pick-up option from a target system. You would need to implement your own interaction logic in that case.

</details>

<details>

<summary>Can multiple boomboxes play at the same time?</summary>

Yes. Each boombox entity gets a unique sound ID (`id_<entityId>`), so multiple boomboxes can stream different tracks simultaneously without interfering with each other.

</details>

<details>

<summary>Does sound sync across all players?</summary>

Yes. When a player presses Play, the server relays the sound event to all connected clients via `TriggerClientEvent(-1, ...)`. Every player within the configured distance will hear the music.

</details>

<details>

<summary>Can I change the boombox prop model?</summary>

The prop is hardcoded as `prop_boombox_01` in `client/client.lua`. To change it, find all references to `prop_boombox_01` in the client script and replace them with your desired prop hash string.

</details>

<details>

<summary>Is the NUI customizable?</summary>

Yes. The entire NUI is a self-contained file at `html/index.html`. Edit the `:root` CSS variables block at the top of the `<style>` section to change the color scheme. Replace `html/logo.png` with your own logo image. The layout and animations are all in CSS and can be freely modified.

</details>

<details>

<summary>What YouTube URL formats are supported?</summary>

The following formats are parsed for video ID extraction (for thumbnail and title fetching):

| Format                                    | Supported |
| ----------------------------------------- | --------- |
| `https://www.youtube.com/watch?v=VIDEOID` | ✓ Yes     |
| `https://youtu.be/VIDEOID`                | ✓ Yes     |
| `https://www.youtube.com/embed/VIDEOID`   | ✓ Yes     |
| `https://www.youtube.com/v/VIDEOID`       | ✓ Yes     |

</details>

<details>

<summary>How many songs can a player save?</summary>

There is no hard limit enforced by the script. The database will store as many rows as you allow. If you want to cap it, add a count check to the `moh-boombox:save` server event handler in `server/server.lua`.

</details>

<details>

<summary>Can I use this on a standalone server (no ESX/QB)?</summary>

No. The script currently requires either ESX or QBCore for item management, saved songs callbacks, and admin checks. The sound relay and sync logic would work standalone, but the item and database features depend on a framework.

</details>

<details>

<summary>Will the boombox disappear after a server restart?</summary>

Yes. Boombox entities are not persisted between restarts — they exist only as in-world props for the current session. Saved songs in the database are persistent, so players can replay their saved tracks after a restart. If you need persistent world objects, you would need to add your own entity persistence logic.

</details>


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://mohssins.gitbook.io/mohscriptsdocs/moh-boombox/faq.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
