Dominó Game
Installation
Installation
1. Drop the resource
Extract the package into your resources folder. The final path should look like:
server-data/resources/[suty]/suty-domino/
The folder must be named exactly suty-domino. A renamed copy stops itself and prints FATAL: resource must be named "suty-domino". Check that fxmanifest.lua sits directly inside the folder, with no double folder like suty-domino/suty-domino/.
Props, animations, sounds and the placement gizmo all ship inside the resource. You don't need object_gizmo or any emote menu to play.
2. Game build and OneSync
Sitting at the table uses an animation from The Contract update, so the server must enforce game build 2545 or newer in server.cfg:
sv_enforceGameBuild 2545
Any newer build works too. OneSync must be enabled on the server.
With an older game build, tables can be placed but nobody can sit. Players get «No se pudo iniciar la animación de sentado» (English locale: «Could not start the sitting animation.»).
3. Start order in server.cfg
Ready-made examples live in install/server/. Merge only the one for your framework into your server.cfg, without duplicating resources you already start. suty-domino goes after the framework, the inventory and the target.
setr inventory:framework "qbx"
ensure oxmysql
ensure ox_lib
ensure qbx_core
ensure ox_inventory
# ox_target or qb-target
ensure ox_target
ensure suty-domino
ensure oxmysql
ensure ox_lib
ensure qb-core
# use ONE of the next two lines
ensure qb-inventory
# ensure ox_inventory
# use ONE of the next two lines
ensure ox_target
# ensure qb-target
ensure suty-domino
With ox_inventory on QB-Core, set inventory:framework for your QB bridge before any resource starts.
setr inventory:framework "esx"
ensure oxmysql
ensure ox_lib
ensure es_extended
ensure ox_inventory
# ox_target or qb-target
ensure ox_target
ensure suty-domino
qs-inventory can't run next to another inventory. Install it with Quasar's own guide first and check that it works, then start it before the domino:
ensure oxmysql
ensure ox_lib
# your framework (only one)
ensure qbx_core
# ox_target or qb-target
ensure ox_target
ensure MugShotBase64
ensure qs-inventory-objects
ensure qs-inventory
ensure suty-domino
The setr inventory:framework line belongs to ox_inventory: you don't need it with qs-inventory.
Config.Framework = 'auto' looks for qbx_core, then qb-core, then es_extended. Start only one framework.
4. Items
Two items are required:
| Item | Label | What it does | ox_inventory export |
|---|---|---|---|
domino_table |
Mesa de dominó | Portable table with its four chairs | suty-domino.useTable |
domino_case |
Estuche de dominó | Wooden case with the 28 tiles. Use it seated at a table | suty-domino.useCase |
Pick the tab for your inventory. Paste the entries inside the existing item table. Don't replace the file, don't add a second return, and don't duplicate names that already exist.
Add to ox_inventory/data/items.lua (works on QBX, QB-Core and ESX):
['domino_table'] = {
label = 'Mesa de dominó',
weight = 10000,
stack = false,
close = true,
consume = 0,
description = 'Mesa portátil de dominó con cuatro sillas. Las fichas se llevan en un estuche aparte.',
client = { export = 'suty-domino.useTable', image = 'domino_table_custom.png' }
},
['domino_case'] = {
label = 'Estuche de dominó',
weight = 800,
stack = false,
close = true,
consume = 0,
description = 'Estuche de madera con 28 fichas de doble seis. Úsalo sentado en una mesa de dominó.',
client = { export = 'suty-domino.useCase', image = 'domino_case.png' }
},
Keep consume = 0 and stack = false. The domino takes the item when you place the table or load the case, and gives it back when you pack up. If the inventory consumed it too, players would lose an extra one. Don't register a second usable item for these names.
Add to QBCore.Shared.Items (or QBShared.Items) in qb-core/shared/items.lua:
domino_table = { name = 'domino_table', label = 'Mesa de dominó', weight = 10000, type = 'item', image = 'domino_table_custom.png', unique = true, useable = true, shouldClose = true, description = 'Mesa portátil de dominó con cuatro sillas. Las fichas se llevan en un estuche aparte.' },
domino_case = { name = 'domino_case', label = 'Estuche de dominó', weight = 800, type = 'item', image = 'domino_case.png', unique = true, useable = true, shouldClose = true, description = 'Estuche de madera con 28 fichas de doble seis. Úsalo sentado en una mesa de dominó.' },
Keep unique = true and useable = true: each table and case keeps its own data (table rules, tile style) and must never stack. The domino registers the usable items by itself, so don't add another CreateUseableItem for them.
Copy the entries from install/qs-inventory/items.lua:
| Framework | Paste them in |
|---|---|
| QBX and ESX | qs-inventory/shared/items.lua |
| QB-Core | qb-core/shared/items.lua (qs-inventory reads QB-Core's items from there) |
Keep unique = true on the table, the case and the six-packs, and don't add a client = { export = ... } field. The domino registers its items in qs-inventory on its own. You can also create them in /inventorycreator → Items with the same names, Unique on for the table, case and six-packs, and Usable on for all of them.
Item images
The package ships every item image in install/ox_inventory/images/. Copy them to your inventory's image folder, keeping the file names:
| Inventory | Folder |
|---|---|
| ox_inventory | ox_inventory/web/images/ |
| qb-inventory | qb-inventory/html/images/ |
| qs-inventory | the folder that holds its stock images |
The two required images are domino_table_custom.png and domino_case.png.
Drinks (optional)
The same item files bring the drinks. Copy only the ones you want, plus their images.
| Item | Label | Type |
|---|---|---|
suty_beer_brisa |
Brisa Verde | Beer, bottle |
suty_beer_sol |
Sol de Isla | Beer, bottle |
suty_beer_costa |
Costa Fina Light | Beer, bottle |
suty_beer_brisa_can |
Brisa Verde (lata) | Beer, can |
suty_beer_sol_can |
Sol de Isla (lata) | Beer, can |
suty_beer_costa_can |
Costa Fina Light (lata) | Beer, can |
suty_malta_indigena |
Malta Indígena | Non-alcoholic, bottle |
suty_soda_sprunk |
Sprunk | Soda, bottle |
suty_soda_ecola |
eCola | Soda, bottle |
suty_soda_sprunk_can |
Sprunk (lata) | Soda, can |
suty_soda_ecola_can |
eCola (lata) | Soda, can |
suty_sixpack_brisa |
Six pack Brisa Verde | Six-pack, 6 bottles |
suty_sixpack_sol |
Six pack Sol de Isla | Six-pack, 6 bottles |
suty_sixpack_costa |
Six pack Costa Fina Light | Six-pack, 6 bottles |
| Inventory | Copy the entries from |
|---|---|
| ox_inventory | install/ox_inventory/items.lua. Drinks use the export suty-domino.useBeer, six-packs suty-domino.useSixpack |
| qb-inventory | install/qb-core/shared_items.lua (beers, cans and six-packs). The malta and the two sodas are in install/qs-inventory/items.lua, in the same QB-Core format |
| qs-inventory | install/qs-inventory/items.lua |
Six-packs keep the bottles left inside the item, so they must stay non-stackable (stack = false / unique = true).
5. Admin access
Admins can open /dominodiseno, customize tables and use the admin commands. A player is an admin when any of these is true:
| Check | Default |
|---|---|
ACE permission Config.Admin.ace (every framework) |
admin |
| QB-Core: QBCore permission group | admin, god |
| QBX: ACE | admin, god |
| ESX: player group | admin, superadmin |
To use your own ACE instead, set Config.Admin.ace = 'suty.domino.admin' in shared/config.lua before the first start (if the panel already saved that field, change it in the panel). Then add to your permissions:
add_ace group.domino_admin suty.domino.admin allow
add_principal identifier.license:YOUR_LICENSE group.domino_admin
Framework groups still count next to the ACE. Never give this permission to builtin.everyone.
6. Restart and test
Do a full server restart after adding the items: the inventory only loads its item list when it starts. On a healthy boot the console prints the SUTY DOMINO banner with the version and Loaded.
Quick test in game:
- Give yourself one
domino_tableand onedomino_casewith your inventory's admin tool. - Use Mesa de dominó standing and outside a vehicle. Aim at flat ground, turn with the mouse wheel, click or press Enter to place (H switches to the gizmo).
- Sit on a chair with the target eye.
- While seated, use Estuche de dominó: the tiles come out on the table.
- Hold the mouse button and move it to shuffle. When the bar is full, press E to finish and take your tiles.
- When you're done: Put tiles away, then Pack up table. Each item must come back exactly once.
Updating
- Finish the matches first. Hands in progress and match scores are not restored after a restart. Placed tables keep their spot and their items.
- Back up the resource, your inventory data and the server's KVP storage.
- Keep your
shared/config.luaand locale edits, and compare them with the new defaults. - Keep the folder name
suty-domino. - Don't wipe the server KVP like a cache: it holds the panel settings and the placed tables.
