Adding more liveries

Add liveries to a FiveM vehicle, either as _sign textures in the .ytd or as livery tuning parts in carcols.meta, and fix kit ID clashes.

Updated
On this page

A vehicle can get its liveries in two ways, and which one your car uses decides how you add more:

Texture liveriesLivery tuning parts
Where they liveTextures in the vehicle's .ytd fileSeparate .yft models in stream
Set in game withSetVehicleLiverySetVehicleMod (mod type 48)
Files to edit.ytd, vehicles.meta.yft, carcols.meta
Typical usePolice, EMS and fleet carsCars with livery options in the tuning menu

To see which one your car uses, look in its stream folder. Files named like carname_livery1.yft mean tuning parts. Otherwise open the .ytd in OpenIV or CodeWalker and look for textures ending in _sign_1, _sign_2 and so on.

Tools you need: OpenIV or CodeWalker for .ytd files, and any image editor. The vehicle pack's livery template (a .psd or .png) makes placing the design much easier.

Method 1: Texture liveries

  1. Make the design. Paint it on the livery template, keeping the same size as the existing livery textures. Save it as a .png. Leave transparent the areas where the car's paint should show.
  2. Open the .ytd. Copy the vehicle's .ytd from the stream folder to a work folder and open it in OpenIV (turn on Edit mode) or in CodeWalker's texture editor.
  3. Find the last livery. Livery textures are named carname_sign_1, carname_sign_2 and so on. Note the highest number.
  4. Import your design and rename it to the next number. If the last one is police3_sign_4, yours is police3_sign_5. The name must match the others exactly apart from the number.
  5. Save the .ytd and put it back in the stream folder, replacing the old one.
  6. Check the livery flag. Open vehicles.meta, find your car's entry, and make sure FLAG_HAS_LIVERY is in its <flags> line:
xml
<flags>FLAG_HAS_LIVERY FLAG_EXTRAS_REQUIRE FLAG_EMERGENCY_SERVICE</flags>

Flags are separated by spaces. Add it to the existing list rather than replacing the line.

  1. Restart the server.

In game, liveries are numbered from 0, so _sign_1 is livery 0 and _sign_5 is livery 4:

lua
SetVehicleLivery(vehicle, 4) -- shows carname_sign_5
print(GetVehicleLiveryCount(vehicle))

Method 2: Livery tuning parts

Here each livery is a copy of a livery model (carname_livery1.yft, carname_livery2.yft …) with a different texture inside, listed as a tuning part in carcols.meta.

  1. Copy an existing livery model. Take the highest-numbered one, for example sentinel_livery9.yft, and copy it as the next number, sentinel_livery10.yft.
  2. Swap its texture. Open the new file in a tool that edits textures inside .yft models, such as Texture Toolkit or CodeWalker, and replace the livery texture with your design. Keep the exact same texture name, or the model won't find it.
  3. Put the file in stream.
  4. Add the part to carcols.meta. Find the vehicle's kit under <Kits>, and in <visibleMods> copy an existing livery entry and change the model name and label to the new number:
xml
<Item>
  <modelName>sentinel_livery10</modelName>
  <modShopLabel>SENTINEL_LIV10</modShopLabel>
  <linkedModels />
  <turnOffBones />
  <type>VMT_LIVERY_MOD</type>
  <bone>chassis</bone>
  <collisionBone>chassis</collisionBone>
  <cameraPos>VMCP_DEFAULT</cameraPos>
  <audioApply value="1.000000" />
  <weight value="0" />
  <turnOffExtra value="false" />
  <disableBonnetCamera value="false" />
  <allowBonnetSlide value="true" />
</Item>
  1. Restart the server.

From a script, livery parts are mod type 48 and, again, counted from 0:

lua
SetVehicleModKit(vehicle, 0)
SetVehicleMod(vehicle, 48, 9, false) -- the 10th livery part

The new livery doesn't show up

Each kit in carcols.meta has an ID and a name:

xml
<kitName>2984_sentinel_modkit</kitName>
<id value="2984" />

If another vehicle on your server uses the same kit ID, one of them shows the other's parts or none at all. Change the ID to a number no other resource uses, and use the same new name in the vehicle's carvariations.meta:

xml
<kits>
  <Item>2984_sentinel_modkit</Item>
</kits>

The name in carvariations.meta must match <kitName> in carcols.meta exactly. Clearing the server cache does not fix a clashing ID; only a unique ID does.

Saving the livery

Garage scripts in ESX and QBCore save both kinds of livery in the vehicle properties, so once a player picks one, it comes back when the car is taken out again.

Still stuck?Ask on our Discord