Commands#
Starter Pack registers three commands and one key mapping. Their names live in config/main.lua, and the commands themselves in server/custom/commands.lua if you want to extend them.
Command | Who | Description |
|---|---|---|
| Everyone | Opens the picker, after the server's cooldown check. The name is |
| Admins | Opens the creator. Anybody else gets "You do not have permission to use this." In game only. The name is |
| Admins and the server console | Deletes a player's claims so they can claim again. No target clears your own; a server id clears that connected player; |
Open Starter Pack | Everyone | A key mapping in Settings → Key Bindings → FiveM. Unbound unless |
With
Config.CooldownScope = 'character', claims are stored per character, not per licence, so thelicense:…form does not find them. Clear those players by server id while they are online./starterclearcannot be undone.
/starterclear # your own claim
/starterclear 12 # the player with server id 12
starterclear license:abc123… # from the server console, an offline accountClient Exports#
For opening the picker from your own scripts — a spawn selector, a tutorial, a character creator, a radial menu.
Opening and closing
exports['qs-starterpack']:Open() -- the picker
exports['qs-starterpack']:OpenAdmin() -- the creator
exports['qs-starterpack']:Close() -- whichever is open
local open = exports['qs-starterpack']:IsOpen()Open opens straight away, without the lifetime check the command does — the claim itself is still refused on the server if the player is on cooldown. OpenAdmin does not check permissions on the client, but every save is checked on the server, so a non-admin can look but never change anything.
Opening with the cooldown check
To behave exactly like the command — including the "already claimed" notification — ask the server to open it:
TriggerServerEvent('qs-starterpack:server:requestOpen')
-- or, the same thing through the item entry point
exports['qs-starterpack']:UseItem()UseItem is what ox_inventory calls through export = 'qs-starterpack.UseItem'. It does nothing while the picker is already open.
Server Exports#
How another resource drives Starter Pack — handing the pack over at the end of character creation, or checking whether somebody has had theirs.
Open, OpenAdmin and Close
exports['qs-starterpack']:Open(source) -- the picker, no cooldown check
exports['qs-starterpack']:OpenAdmin(source) -- the creator, only if the player is an admin
exports['qs-starterpack']:Close(source)GetPlayerClaim
The player's most recent claim, or nil if they have never claimed (or the database is not ready). It follows Config.CooldownScope, so with character scope it answers for the character they are playing.
local claim = exports['qs-starterpack']:GetPlayerClaim(source)
-- {
-- packId = 'legal',
-- gender = 'female',
-- claimedAt = 1760000000000, -- milliseconds
-- cooldownRemainingSec = -1, -- -1 lifetime, locked · 0 ready · N seconds left
-- }CanPlayerClaim
true when the player has never claimed or their cooldown is over.
-- At the end of your character creation
RegisterNetEvent('my-multichar:server:characterCreated', function()
local src = source
if exports['qs-starterpack']:CanPlayerClaim(src) then
exports['qs-starterpack']:Open(src)
end
end)Events#
Event | Direction | What it does |
|---|---|---|
| Client → server | Open the picker for the sender, after the cooldown check. Limited to five calls every four seconds per player. |
| Server → client | Open the picker, no check. |
| Server → client | Close whatever is open. |
| Server → client | Show a message through |
Hooks#
Hooks are functions of yours that Starter Pack calls at set moments. Each one runs protected, so an error inside your code can never break a claim.
Client — client/custom/main.lua#
Hook | When |
|---|---|
| Before the picker opens. Return |
| Right after the picker has opened. |
| Every notification, when |
function OnBeforeOpen()
if IsPedInAnyVehicle(PlayerPedId(), false) then
TriggerEvent('qs-starterpack:client:notify', 'Step out of the vehicle first.', 'error')
return false
end
return true
endServer — any file in server/custom/#
Define these as global functions in a new file inside server/custom/ — every file there is loaded and left editable.
Hook | When |
|---|---|
| After a successful claim. |
| After the creator's configuration has been saved. |
| When a non-admin types |
-- server/custom/hooks.lua
function OnPlayerClaim(source, packId, gender, delivered, failed)
if packId == 'legal' then
-- e.g. start the player on a civilian job
local Player = exports['qb-core']:GetCoreObject().Functions.GetPlayer(source)
if Player then Player.Functions.SetJob('taxi', 0) end
end
endAbout the Results#
A claim and a creator save both answer with a short code instead of a sentence — cooldown, inventory_full, not_admin — and the interface turns each into a message in the player's language. The full list, and what to do about each, is in Common Errors.



