DashKart docs

Models, props and clothing

Vehicles, props, animations, uniforms and the add-on rider tee.

DashKart is model-agnostic. Every vehicle, prop, animation, customer ped and blip is referenced by name in config/assets.lua, uniforms in config/rider.lua, and every location in config/stores.lua, config/wholesale.lua and config/npc.lua. The defaults are vanilla GTA V, so DashKart works without any streamed files and no code change is ever needed to swap them.

Only ship or stream models you are allowed to use. Free community models usually may not be resold or bundled with another resource.


What can be swapped (config/assets.lua)

Vehicles

Key Default Used for
vehicles.scooter faggio (or the dashkart:scooter convar) rider rental scooter
vehicles.bulk speedo rider rental van (bulk orders, Config.Rider.rental.van)
vehicles.restockVan burrito3 owner’s van run from the wholesale warehouse

vehicleTypes must give the server spawn type for each of them: 'bike' for scooters and motorbikes, 'automobile' for cars and vans. A wrong type makes the spawn fail (Could not spawn rental model ... in the console; the deposit is refunded).

vehicleStyle sets primaryColor / secondaryColor (GTA colour indexes), an optional livery index and the plate prefix (DK → plates like DK1234).

Props

Key Default When it appears
props.tablet prop_cs_tablet in the hand while the tablet is open
anims.carryBag.prop / carryBagFull.prop dk_grocery_bag / dk_grocery_bag_full (fallback prop_cs_shopping_bag) DashKart grocery bag in the rider’s hand on foot: empty while picking at the shelves, full from packed until handover (no emote: an emote menu would show its own bag). The customer walks off with it. carryBagFull.propLeft is the second bag of a big order in the left hand
props.packBox prop_cs_cardbox_01 test box placed by /dk_bridgetest (debug only)

Attached props take model, bone (ped bone id), offset and rotation. Adjust offset and rotation until a custom prop sits right; restart the resource to apply.

Scooter delivery box

Config.Assets.vehicleProps.scooterBox mounts a delivery carrier on the rental scooter: the insulated bag dk_delivery_bag by default, or the hard boxes dk_delivery_box_lime / dk_delivery_box (all stream from the dashkart_props resource). Everyone sees it, and it is removed with the rental.

  • model, bone (default chassis), and positions per vehicle spawn name; default covers any model not listed.
  • Tune the position in game: turn on debug mode, rent a scooter and run /dk_boxpos x y z [rotX rotY rotZ]. The box moves live and F8 prints the line to paste into positions.
  • scooterBox = false removes the box. On servers with sv_entityLockdown the box is skipped (clients cannot create objects there).
  • openable (default on): the bag is two models, dk_delivery_bag_body and dk_delivery_bag_lid, hinged at the back top edge (hinge). The lid opens while the rider puts the order in or takes it out (Config.Rider.orderBag), and the order bag (inside) sits in the bag while stowed. Tune the opening with /dk_lid <angle> (debug mode), /dk_lid close shuts it. openable = nil uses the closed model instead. On the van the rear doors open instead.
  • Source files (Blender scene, texture) are in the repository under assets_src/delivery_box/; they are not part of the release package. The opening bag is rebuilt from assets_src/insulated_bag/dk_delivery_bag.blend with tools/blender/split_bag_lid.py (split + front panel patch) and tools/blender/build_bag_lid.py (Sollumz + PyMateria export of both .ydr files and dk_props.ytyp); tools/blender/render_bag_lid.py renders previews.
  • Bag colour: lime #66B81F (matches the lime Faggio and dk_delivery_box_lime). Texture source: assets_src/insulated_bag/atlas_lime.html over base_lime.png (made from base_teal.png with tools/texture/recolor.js); the Dash Teal version is kept as atlas.html / dk_delivery_bag_teal.dds. dk_delivery_bag.dds is always the shipped texture. To change the colour of the streamed models without re-exporting, encode the new texture the same way and swap it in with tools/texture/ydr_texture.js patch.

Van cargo (big orders)

Bags loaded into the rental van stay visible in its cargo area (Config.Assets.vanCargo): model, and per vehicle spawn name a floor height (above the van’s lowest point), an inset from the rear bumper and up to five slots (x across, y forward, z up). Tune live with /dk_cargopos <floor> [inset] in debug mode while the van is rented. The second bag a rider carries hangs from the left hand (Config.Assets.anims.carryBagFull.propLeft, tune with /dk_bagpos2).

Animations

Key Used for
anims.tablet holding the tablet
anims.pack packing at the pickup point (scenario is used when set)
anims.pick grabbing items at a shelf
anims.handover / anims.receive rider hands over / customer receives
anims.rude rude customer event
anims.phoneCall calling the customer (no-answer event)
anims.customerIdle scenario the customer plays while waiting at the door

Each animation is { dict, clip, flag }, optionally with emote (an rpemotes-reborn / scully emote name, used when that menu runs), prop ({ model, bone, offset, rotation }) and scenario (a GTA scenario instead of the clip). The order bag steps use stowBag / takeOutBag (reach into the delivery bag) next to carryBag / carryBagFull.

Customer peds and blips

  • customerPeds: pool of ped models, one picked at random per order. Add or remove models freely; add-on peds work once they are streamed.
  • blips.store, blips.warehouse, blips.dropoff: sprite, colour and scale (route / routeColor for the GPS route to the customer). Hide a store’s blip with blip = false in config/stores.lua.

Using a custom vehicle

1. Stream it

Recommended: keep the model in its own resource (a normal add-on vehicle resource with its stream/ folder and data_file entries for vehicles.meta, carvariations.meta, handling.meta). DashKart then only needs the model name, and DashKart updates never touch your vehicle files. Start that resource before DashKart.

2. Tell DashKart the model

For the scooter, set it from server.cfg without editing any config:

ensure my_scooter_resource
setr dashkart:scooter "my_scooter_model"
ensure dashkart

Use setr (not set) so clients receive it too. For the vans, or if you prefer the config file, edit config/assets.lua:

Config.Assets.vehicles.scooter = 'my_scooter_model'
Config.Assets.vehicles.bulk = 'my_van_model'

A custom scooter stays vehicleTypes.scooter = 'bike'.

3. QBox / QBCore: register the model with the framework

Add-on vehicles must be in the framework’s shared vehicle list, otherwise key and garage scripts do not know them (with qbx_vehiclekeys the server console fills with attempt to call a nil value (global 'GetVehicleClass') for every unknown model, and keys may not be given). Restart the server after editing.

QBox - qbx_core/shared/vehicles.lua:

['my_scooter_model'] = {
    name = 'My Scooter',
    brand = 'Custom',
    model = 'my_scooter_model',
    price = 15000,
    category = 'motorcycles',
    type = 'bike',
    hash = `my_scooter_model`,
},

QBCore - qb-core/shared/vehicles.lua (list format of current QBCore):

{ model = 'my_scooter_model', name = 'My Scooter', brand = 'Custom', price = 15000, category = 'motorcycles', type = 'bike', shop = 'none' },

Older QBCore builds use a keyed table instead (['my_scooter_model'] = { name = ..., model = ..., hash = \my_scooter_model`, … }`): copy the format of the entries already in your file.

ESX needs no registration for spawning or DashKart’s own logic.

Speed of fast add-on scooters

Some community scooters ship very high top speeds. The speed is set by the model’s handling.meta (fInitialDriveMaxFlatVel), not by DashKart. Lower it in the vehicle resource if deliveries feel too fast. DashKart’s anti-farm flags deliveries faster than Config.Economy.antiFarm.maxPlausibleSpeed (45 m/s ≈ 162 km/h).


Custom props

  1. Put .ydr / .ytd files (and the .ytyp declaring the archetype) in a streaming resource of your own, with:
    data_file 'DLC_ITYP_REQUEST' 'stream/my_props.ytyp'
  2. Change the model name in config/assets.lua, for example:
    Config.Assets.anims.carryBag.prop.model = 'my_bag'   -- and remove `emote` so your model is used
  3. Adjust bone, offset and rotation, then restart DashKart.

Keep custom models in their own resource (or in dashkart_props/stream), never inside dashkart: restarting a resource that streams models crashes connected game clients, and a separate resource keeps your files safe when you update DashKart. Never restart dashkart_props on a live server; new or changed models need a full server restart.


Uniforms (config/rider.lua → Config.Rider.uniform)

DashKart ships its own rider tee as add-on clothing in dashkart_props (collections mp_m_dashkart and mp_f_dashkart, torso component 11, drawable 0): Dash Teal with the logo on chest and back, ink collar and cuffs. It is added next to the game’s clothes, nothing is replaced. Address add-on clothing by collection, since its global drawable number differs per server:

[11] = { collection = 'mp_m_dashkart', drawable = 0, texture = 0 },

Plain { drawable = n, texture = n } entries still work for vanilla or EUP clothing. Changing the tee’s files needs a full server restart (never restart dashkart_props while players are connected).

The tee is invisible (torso missing, arms and pants visible)

Cause: your server key is not allowed to stream add-on clothing. FiveM only streams add-on ped clothing (any mp_m_freemode_01_* / mp_f_freemode_01_* pack, not just DashKart’s) when the server’s license key has the Element Club Argentum tier or higher, or when the server has 10 slots or fewer. Otherwise the game still loads the pack’s metadata and “wears” the item, but the model is never streamed, so the torso is simply missing. GTA’s own clothing is not affected.

Fix, pick one:

  • Use a key with Argentum or higher (regenerate the key on the Cfx.re key page after subscribing), or
  • run with sv_maxclients 10 or lower (fine for test servers), or
  • skip the add-on tee: replace the [11] entries in Config.Rider.uniform with a vanilla torso, e.g. [11] = { drawable = 0, texture = 0 }, and stop streaming the tee files.

How to tell it is this and not a broken file: dk_clothtry 1 (debug mode) puts on a Rockstar tee from the game’s own clothing pack. If that one shows while dk_clothtry 2 (the DashKart tee) is invisible, the tee is being blocked, not broken. Verified on the dev server: invisible at sv_maxclients 48, visible at 10 with the same files.

Not the cause, ruled out while chasing this (keep them in mind when editing the tee):

  • Texture files must stop their mipmaps at 4x4 (1024 px → 9 levels, DXT1 like Rockstar’s _uni diffuse). A chain down to 1x1 imported into CodeWalker with the wrong data size.

  • The tee model is Rockstar’s base tee (jbib_000_u) with ped_palette.sps swapped to ped.sps so the full-colour texture shows; the UV layout is unchanged.

  • Per gender (male / female): components (id → { drawable, texture }) and props. Component ids: 1 mask, 3 arms, 4 legs, 5 bag, 6 shoes, 7 accessory, 8 undershirt, 9 armour, 10 decals, 11 torso. Prop ids: 0 hat, 1 glasses, 2 ears, 6 watch, 7 bracelet.

  • The listed slots are saved on clock-in and restored on clock-out.

  • Only freemode peds (mp_m_freemode_01 / mp_f_freemode_01) can wear components.

  • Appearance resources or EUP: set onApply(ped, gender) and onRestore(ped) (client functions). They replace the built-in logic. Example with illenium-appearance is in the config comments.

  • enabled = false leaves clothing alone.


Stores and MLOs (config/stores.lua)

Stores are defined only by coordinates; nothing references an interior. Point these fields at your MLO or a plain exterior:

Field What
duty counter: clock in/out, queue, rentals and the Store office (coords + radius)
pickup packing point for stores without shelves
vehicleSpawns list of vec4 rental spawn spots; the first free one is used
vehicleReturn where rentals are returned (coords + radius)
zone box around the store (coords, size, rotation); leaving it starts the delivery
shelves optional shelf layout, see below

Do not rename a store id after the first start: it is the database key.

Shelf layouts (shelf picking)

A store with shelves packs orders by visiting each shelf that holds items of the order; a store without shelves uses the single pickup point. Shelves map to catalog categories (dairy, groceries, snacks, beverages, essentials, or '*' for everything not matched elsewhere).

Easiest: record them in game. Turn on debug mode (setr dashkart:debug "true" in server.cfg), stand at each shelf facing it, and run /dk_shelf add dairy Milk fridge (category list, optional label). /dk_shelf show draws them, remove <n> / clear fix mistakes. Layouts are saved to data/shelves.json and override the config for that store. /dk_shelf export prints the same layout as config:

shelves = {
    { coords = vec4(30.33, -1345.64, 29.48, 269.3), categories = { 'dairy' }, label = 'Milk fridge' },
    { coords = vec4(29.54, -1342.72, 29.48, 0.0), categories = { 'beverages' } },
},

Paste it inside the store entry in config/stores.lua if you prefer to keep layouts in config. The default package includes an 8-shelf layout for the Strawberry store.

For finer aisles, a shelf can also list exact catalog items: items = { 'dk_chocolate', 'dk_cookies' } (in config or in data/shelves.json). An item listed on a shelf always goes there, before category matching; everything else falls back to categories and then '*'.

Delivery points (config/npc.lua → Config.Npc.dropoffs)

Each point is a door or curb spot: { coords = vec4(x, y, z, heading), type = 'house' | 'apartment' | 'office' } grouped by zone. With vec3 the customer turns to face the rider. Optional alt sets the other door used by the wrong-gate event. Orders pick points between Config.Npc.minDistance and maxDistance from the store.

Debug-mode tools for your map:

  • /dk_tpdrop <index>: visit a point.
  • /dk_dropadd [type] [zone]: add the door you stand at.
  • /dk_dropaudit: visits every point, moves points standing on a road onto the pavement or disables them.

Both save to data/dropoffs.json, which is applied on start. Corrections are keyed by the original coordinates, so if you change a point’s coords in config its old correction no longer applies.

Wholesale warehouse (config/wholesale.lua)

coords (counter), vanSpawn (vec4, van run van) and blip. Move it anywhere.