Carvariation and tuning part for addons

Hi ,

As I know , I think I’m not the only one to have this problem. My tuning part not showing up in ls custom . Also , color of the vehicle when I go to showroom still always the same …no variations at all like my GTR still always showing green army matte when I scroll vehicle list . Its doing this for many of my add ons except supra working great at my last souvenir . I follow multiple tutorials on web , youtube and nothing is working . By luck , there is no error showing at me . I put all yft ytd xlm in my stream folder and meta data files in the car folder .

Does anyone have found something for this ?

4 Likes

Hello! I will divide it into two parts to make it simple.

Tuning

Are you adding vehicle_names.lua too in your add-on folder? I think that’s the point. Most of the add-on have got global.gxt2 file in the dlc.rpf.
Usually the correct path to find it is dlc.rpf/x64/data/lang/yourlanguagedlc.rpf/global.gxt2
You open it and you have to copy it in the vehicle_names.lua file.

I show you an example - you find this in the global.gxt2 file:

    0x004D4C50 = NISSAN 
    0x2C80553E = Spolier D 
    0x5A07304B = Spoiler E 
    0x5D1DDD67 = Paintable 
    0x6D787E1C = Paintable 
    0x7EE320F1 = Paintable 
    0x47FB0C33 = Spoiler B 
    0x778CEB56 = Spoiler C 
    0x912F1E9A = Spoiler A 
    0x7885F497 = Rollcage 
    0x21733EE8 = Spoiler G 
    0xA722CA58 = GT-R NISMO 
    0xACF5D972 = GT3 Hood 
    0xC88CED4D = Rollcage&RaceSeats 
    0xD4BCA57C = Spoiler H 
    0xF0D904C7 = Roof Hood 
    0xF33BE27A = Spoiler F 
    0xFE9AA04A = Hood&Spoiler 
    0xFFB8FBF8 = Roof Spoiler 

In this case you have to create vehicle_names.lua file and put it in your add-on folder with all meta files.
Open it and copy this:

function AddTextEntry(key, value)
	Citizen.InvokeNative(GetHashKey("ADD_TEXT_ENTRY"), key, value)
end

Citizen.CreateThread(function()
  AddTextEntry('0x004D4C50', 'NISSAN')
  AddTextEntry('0x2C80553E', 'Spolier D')
  AddTextEntry('0x5A07304B', 'Spoiler E')
  AddTextEntry('0x5D1DDD67', 'Paintable')
  AddTextEntry('0x6D787E1C', 'Paintable')
  AddTextEntry('0x7EE320F1', 'Paintable')
  AddTextEntry('0x47FB0C33', 'Spoiler B')
  AddTextEntry('0x778CEB56', 'Spoiler C')
  AddTextEntry('0x912F1E9A', 'Spoiler A')
  AddTextEntry('0x7885F497', 'Rollcage')
  AddTextEntry('0x21733EE8', 'Spoiler G')
  AddTextEntry('0xA722CA58', 'GT-R NISMO')
  AddTextEntry('0xACF5D972', 'GT3 Hood')
  AddTextEntry('0xC88CED4D', 'Rollcage&RaceSeats')
  AddTextEntry('0xD4BCA57C', 'Spoiler H')
  AddTextEntry('0xF0D904C7', 'Roof Hood')
  AddTextEntry('0xF33BE27A', 'Spoiler F')
  AddTextEntry('0xFE9AA04A', 'Hood&Spoiler')
  AddTextEntry('0xFFB8FBF8', 'Roof Spoiler')
end)

It works for me, I’m using it for a Nissan GT-R Nismo add-on.

Car colors and liveries

You have to edit carvariations.meta file inside your addon folder. Example:
look for this code in your carvariations.meta file

      <colors>
        <Item>
          <indices content="char_array">
            73 
            70
            73
            156 
          </indices>
          <liveries>
            <Item value="true" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
          </liveries>
        </Item> 
      </colors>

73, 70, 73 and 156 are the colors for that specific model spawn. All those “item values” you see mean if you want to enable or not a specific livery - you have to test it yourself to get the one you want.
If you want to put a static color just replace those numbers (Go here and you will find all different colors codes)
If you want to choose more colors combination just copy this (and copy it again as much as you want):

      <colors>
        <Item>
          <indices content="char_array">
            73 
            70    -- mixed combination
            73
            156 
          </indices>
          <liveries>
            <Item value="true" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
          </liveries>
        </Item> -- where first combination ends
        <Item> -- where second one starts
          <indices content="char_array">
            83
            83    -- full blue color
            83
            83
          </indices>
          <liveries>
            <Item value="true" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
          </liveries>
        </Item> -- where second combination ends
        <Item>
        [...]
        </Item>
      </colors>

I hope I helped you :slight_smile:

12 Likes

Unbelievable how many questions I had that you answered with this. Thanks

1 Like

No problem man, I’m happy to help!

4 Likes

Hi borgo,

Unfortunately , it didn’t worked for me :rage: the result still the same.

I’m going to put some screenshot to show how I did it . I tested 2 differents model of Nissan GTR. I follow your’e instruction .

Also I looked at the nismo and yes ther was only one color setted . I copy color from the other GTR model and this litle b**** still spawn green.

<?xml version="1.0" encoding="UTF-8"?>

<CVehicleModelInfoVariation>
  <variationData>
    <Item>
      <modelName>gtrnismo17</modelName>
      <colors>
        <Item>
          <indices content="char_array">
            29
            29
            6
            0
          </indices>
          <liveries>
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
          </liveries>
        </Item>
        <Item>
          <indices content="char_array">
            36
            36
            6
            0
          </indices>
          <liveries>
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
          </liveries>
        </Item>
        <Item>
          <indices content="char_array">
            64
            64
            6
            0
          </indices>
          <liveries>
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
          </liveries>
        </Item>
        <Item>
          <indices content="char_array">
            112
            44
            6
            0
          </indices>
          <liveries>
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
            <Item value="false" />
          </liveries>
        </Item>
      </colors>
      <kits>
        <Item>0_default_modkit</Item>
      </kits>
      <windowsWithExposedEdges />
      <plateProbabilities>
        <Probabilities>
          <Item>
            <Name>Standard White</Name>
            <Value value="100" />
          </Item>
        </Probabilities>
      </plateProbabilities>
      <lightSettings value="0" />
      <sirenSettings value="0" />
    </Item>
  </variationData>
</CVehicleModelInfoVariation>

Eextremely weird , when I putted my Nismo in my garage and get it out another time after, It spawned with a spoiler on it to troll me out !

I don’t know what to do…

Sorry for my english a bit , i’m french .

I forgot , I tried this model :

and this model I think you have

Hi Oliver, well I’ll look into it when I am home. Btw did you try setting one (another) color only? I mean replace the original single color the car had. Give it a try.

For the tuning parts, did you try customize the car using a trainer too? If yes, no tuning parts available?

Let me know!

I didn’t tried another color only . I tried to customise both method, with lambda menu after I spawned with it but there is no option for exemple spoiler , bumpers, bodykit . Option to change wheel are there but it doing nothing when I try to get new one wheels and I also tried in LS customs like my screenshot .

I should have my working add-on folder. I’ll create a new release post if you want I can give you the link.

It would be great thanks , but if you look at my shots , do you see something wrong ?

Wait a moment, I just noticed this:

You have to put all modded parts files (they usually are in an rpf called like vehiclemods.rpf that you can find in the dlc.rpf) in the stream folder of your addon car.
It could be the problem.

EDIT I mean it should be like this:
gtr


I’m at work now lol . Yes I know how to do this part , but maybe I didn’t paid attention to tuning part on nismo because I don’t rembember if there was a vehiclemods.rpf with it.

The other regular GTR has it , I made what you said ,go to gxt files (after few minutes of search , I found the file …lol) , create a vehicle name with data of gxt , putted my stream thing in my stream folder , putt my metas and this one always spawn black color and there was no black color at all in my carvariations of the regular GTR . .

Do you stream XML file to ?

Ok let’s do this: I’ll release mine working. What color(s) do you want me to add?

Nope

White, Black ,Orange , Blue , Red , Gray. I’m glad that you want to help me like this , I really appreciate .

Dumb question like that , is this a problem linked to the “custom” ls custom made by the n3mtv team ? If you don’t know its ok , but if the lamba menu doesn’t show any tuning parts , it shouldn’t be a ls custom problem …

Here’s the correct carvariations.meta (4.2 KB) it gives you all GT-R Nismo with full plate of all of your chosen colors and an additional Ice White one with the livery enabled. I wrote some comments inside it to let you understand better. (If you need, just ask me). To spawn the color you want, you just have to spawn and spawn and spawn again with the trainer until you get it using model name gtrnismo17 then I suggest you to save the one(s) you want with the in-tranier feature to be able to spawn it when you want later.

EDIT: Fixed model names in the file according to the one you’re using.
IMPORTANT: Remember to replace the “1525” in line 136:

<Item>1525_gtrnismo17_modkit</Item>

with the code you are using in your .meta files.
ALSO, I read somewhere that if you think you did it good but you can’t see tuning parts, maybe you’re already using that modkit code.

Actually I don’t know. Btw I noticed you can add the spoiler by trainer simply going in -> “Modifications” -> “2nd page” -> “Toggle Extra 1” switching between ON and OFF.

1 Like

I will try this tonight after my work day . Thanks.

Can you tell me where you found mod parts for the nismo made by JustRiko because I don’t find them …

Edit : woops I think I miss understanding your model on your side because I looked at comment of JustRikko and He don’t make tuning mods on his add ons . I 'm lost a bit lol

If I don’t remember wrong, I took this one:

Ahh that is why I didn’t found tuning part on mine lol .

I start from the begining with the GTR model by YCA-y97y .

I made my carvariations with your’e color . I created my vehicle_name like this :

function AddTextEntry(key, value)
	Citizen.InvokeNative(GetHashKey("ADD_TEXT_ENTRY"), key, value)
end

Citizen.CreateThread(function()
  AddTextEntry('0x0F5EED98', 'Liberty Walk')
  AddTextEntry('0x1B02843C', 'Liberty Walk')
  AddTextEntry('0x31A6DAD4', 'RocketBunny')
  AddTextEntry('0x847AD6BF', 'Nismo')
  AddTextEntry('0x9790D1BD', '2017 NISSAN GTR')
  AddTextEntry('0x23583E37', 'Nismo')
  AddTextEntry('0x756930C0', 'Liberty Walk')
  AddTextEntry('0xA2321340', 'RocketBunny')
  AddTextEntry('0xB6B13B2B', 'RocketBunny')
  AddTextEntry('0xB480B7DD', 'Nismo')
  AddTextEntry('0xC3C1CD70', 'RocketBunny')
  AddTextEntry('0xC6E70556', 'Liberty Walk')
  AddTextEntry('0xD1D0698D', 'Nismo')
  AddTextEntry('0xDC75E655', 'Liberty Walk')
  AddTextEntry('0xF15C9022', 'RocketBunny')
end)

I change ID number of the modkit as recommend in comments in the download page .
My carvariations look the same as you , except I delete ice white with livery .
My GTR still only spawning in black and blue seats with lambda menu even if I spam the spawn and in showroom in black and white/gray seat… (I think he takes the first color of youre carvariations)
Is this something about maxnumofsamecolor ine my vehicles.meta ?

Screenshots again …

I start to desperate a bit … :disappointed_relieved:

Here is some working Modkit ID’s:

696
754
897
968
1009
1010
1011
1012
1013
1015
1021
1125
1518
1519
1520
1526
1528
1531
1532
1533
1534
1535

5 Likes

I had the same issue as well, I have the Tunnings RPF and did the Objects in LUA and It was still causing issues