Installation
How to install Frozen Christmas Lottery: server.cfg order, admin access and the ticket items for ox_inventory, QBCore, Qbox, ESX and vRP.
On this page
- Put the
frozen_xmaslotteryfolder in yourresourcesdirectory. - Add
ensure frozen_xmaslotteryto yourserver.cfg, below your framework, your inventory andoxmysql. - Give your admins access (see below).
- Add the four ticket items to your inventory (see below) and copy the pictures from
[IMAGES]into your inventory's image folder. - Restart the server.
- In game, open
/xmasadmin→ Kiosks, walk to where the booth should be and press Place at my position.
The database tables are created on first start, so there is no SQL to import. Without oxmysql the script saves to the server's own KVP storage instead.
config.lua only tells the script what your server runs. Everything is on auto, which works on almost every server:
Config.Framework = 'auto' -- 'esx', 'qb', 'qbx', 'vrp', 'ox', 'nd', 'standalone'
Config.Inventory = 'auto' -- 'ox' or 'framework'
Config.Target = 'auto' -- 'ox_target', 'qb-target', 'none' (press E)
Config.Notify = 'auto' -- 'ox_lib', 'esx', 'qb', 'gta'
Config.Storage = 'auto' -- 'oxmysql' or 'kvp'Admin access
A player can open /xmasadmin when their framework group is god, superadmin or admin (edit Config.AdminGroups), or when they have the ace permission. In server.cfg:
add_ace group.admin frozenlottery.admin allowTicket items
The four default lotteries use these items. money_ticket and item_ticket have the same names as in v1, so old tickets keep working. Every lottery can use any item: set it in /xmasadmin → Lotteries, and the 📋 button next to the item field shows the exact code for that item.
ox_inventory
In ox_inventory/data/items.lua:
['money_ticket'] = { label = 'Candy Cane Scratch', weight = 10, stack = true, close = true, server = { export = 'frozen_xmaslottery.useTicket' } },
['item_ticket'] = { label = "Santa's Sack ticket", weight = 10, stack = true, close = true, server = { export = 'frozen_xmaslottery.useTicket' } },
['wheel_ticket'] = { label = 'Frosty Wheel ticket', weight = 10, stack = true, close = true, server = { export = 'frozen_xmaslottery.useTicket' } },
['golden_ticket'] = { label = 'Golden Star ticket', weight = 10, stack = true, close = true, server = { export = 'frozen_xmaslottery.useTicket' } },This works on every framework that runs ox_inventory, including standalone.
QBCore / Qbox without ox_inventory
In qb-core/shared/items.lua:
money_ticket = { name = 'money_ticket', label = 'Candy Cane Scratch', weight = 10, type = 'item', image = 'money_ticket.png', unique = false, useable = true, shouldClose = true, description = 'Merry Christmas!' },
item_ticket = { name = 'item_ticket', label = "Santa's Sack ticket", weight = 10, type = 'item', image = 'item_ticket.png', unique = false, useable = true, shouldClose = true, description = 'Merry Christmas!' },
wheel_ticket = { name = 'wheel_ticket', label = 'Frosty Wheel ticket', weight = 10, type = 'item', image = 'wheel_ticket.png', unique = false, useable = true, shouldClose = true, description = 'Merry Christmas!' },
golden_ticket = { name = 'golden_ticket', label = 'Golden Star ticket', weight = 10, type = 'item', image = 'golden_ticket.png', unique = false, useable = true, shouldClose = true, description = 'Merry Christmas!' },ESX without ox_inventory
INSERT IGNORE INTO items (name, label, weight) VALUES
('money_ticket', 'Candy Cane Scratch', 1),
('item_ticket', 'Santa''s Sack ticket', 1),
('wheel_ticket', 'Frosty Wheel ticket', 1),
('golden_ticket', 'Golden Star ticket', 1);vRP
- vRP 0.5 (Dunko): the ticket items are registered automatically with a "Use" option. If an item already exists in
cfg/items.lua, add a Use choice there that calls the export below. - vRPex and forks: add the items to your item list, and call the export from the item's use code:
exports.frozen_xmaslottery:UseTicket(source, 'money_ticket')- On any vRP server, tickets can always be played at a booth ("Play a ticket from your pocket").
- Money:
moneyis the wallet,bankis the bank andblack_moneyis thedirty_moneyitem.
Any other inventory
Call exports.frozen_xmaslottery:UseTicket(source, itemName) from the inventory's use-item code.
Supported resources
| Frameworks | ESX Legacy and old ESX, QBCore, Qbox, vRP 0.5 (Dunko) and vRPex, ox_core, ND_Core, standalone (with ox_inventory) |
| Inventories | ox_inventory (any framework), ESX and QB inventories and everything that hooks into them (qs, ps, lj, codem, core and more) |
| Target | ox_target, qb-target, or a "press E" prompt |
| Notifications | ox_lib, ESX, QB or GTA |
| Database | oxmysql, or the server's KVP storage |
Next steps
- Lotteries & prizes: check the prizes use items that exist on your server
- Kiosks & booth: place your booths
- Grand draw: set the draw time and the pot
- Common issues: if something doesn't work
Still stuck?Ask on our Discord