AI vehicles variants

Dejf94
Posts: 20
Joined: 13 Apr 2019 13:58

AI vehicles variants

#1 Post by Dejf94 » 13 Oct 2020 08:04

Hello,

I have question I can't solve, I don't know what am I doing wrong. I'd like to make a second variant of existing mod AI car. I'd like to have the same car with two types of wheels. The variant vehicle "traffic.Xxx2" should follow the country traffic spawn by it's parental vehicle def "traffic.Xxx1". But no matter what I do, the game would not accept it, although I followed the example of Jazzycat AI vans, which he has several variants in one def file. I understand it needs custom chassis.sii I guess, and different name of traffic.Xxx1 specified as the variant in the line 'variant: traffic.Xxx2'. But the game won't accept it and keeps failing with the note, that the variant is not in the traffic_storage. But Jazzycat has in the traffic storage only parental vehicles, not it's variants. How can I do variants then?

Thanks in advance.

D.

User avatar
tinusman
Posts: 528
Joined: 11 Jun 2013 09:45
Location: driver`s seat

Re: AI vehicles variants

#2 Post by tinusman » 13 Oct 2020 11:05

if you only want different wheels on the same traffic car?
Then goto
def/vehicle/ai/xxx1.sii
open that file and copy it`s hole contend, paste it below the last braked } , in that file.

then only change the lines, (in the new copied) the traffic.xxx1 to traffic.xxx2
and all the
accessories[]: xxx1.chassis to accessories[]: xxx2.chassis
(and fwheels and rwheel to)
also
vehicle_accessory: .xxx1.chassis to vehicle_accessory: .xxx2.chassis
as well as the wheels to
and change the data_path of the wheels to your new choise_wheels.

good luck

Dejf94
Posts: 20
Joined: 13 Apr 2019 13:58

Re: AI vehicles variants

#3 Post by Dejf94 » 13 Oct 2020 11:47

Hello,

I tried, but after that the vehicle xxx2 behaves independent, and does not follow the country spawn density set for parental vehicle. That's the problem. It automatically spawns everywhere with spawn ratio 1. So, if i want to do it that way, do I need to set country spawn ratio even for these variants?

User avatar
tinusman
Posts: 528
Joined: 11 Jun 2013 09:45
Location: driver`s seat

Re: AI vehicles variants

#4 Post by tinusman » 13 Oct 2020 11:53

ad the line
above the line
allow_parked: false
spawn_ratio: 0.x
x is a number , try til it fit`s your liking

other wise: yes you`ll have to set it for every country

Dejf94
Posts: 20
Joined: 13 Apr 2019 13:58

Re: AI vehicles variants

#5 Post by Dejf94 » 13 Oct 2020 15:10

I hoped there is another solution :D But my first guess, that I would have to add every each other to country files, seems to be correct. Sadly :/ Thanks for the answers ;-)

cadenysd
Posts: 17
Joined: 22 May 2020 12:29

Re: AI vehicles variants

#6 Post by cadenysd » 13 Oct 2020 16:21

Apologies in advance, I am fairly new to non-vanilla stuff of ETS2. I just started fiddling around with def files etc so the lines you were using above are familiar to me. I noticed we are unable to change the spawn frequency of individual trucks. I wanted to reduce the spawn frequency of 4x2s and increase that of 6x4s and 6x2s. May I know if there is a way I can do this?

Also, how do I repack the file into a def scs file and put it back in the game?

User avatar
tinusman
Posts: 528
Joined: 11 Jun 2013 09:45
Location: driver`s seat

Re: AI vehicles variants

#7 Post by tinusman » 13 Oct 2020 17:44

cadenysd

AI-Truck`s are not in the country files like ai-cars are. (def/country/`sertanland`/traffic.sii)
so I ques the way to do is a kind of, like mentioned above.

as you are new to modding, First extract de def.scs file in a map of your choce. (use scs_extractor.exe)
The def.scs can be found where you installed the game.
Then you can see / open /and if you need copy files to a map , were you make your changes and mod.

to start testing if this will work, I would go and start with the:
def/vehicle/ai/daf_xf_b_4x2.sui
and
def/vehicle/ai/daf_xf_c_6x4.sui

One`s you made your changes , it is time to make a mod.
it is posible to just put your def folder in the mod_folder.

most likely : make a .scs or .zip file
with re_reconizable name of your choise.zip
Compression method: Store
use winrar / 7.zip or win_zip or what ever paccking software.

PS if anobody knows a better or different way? PLEASE comment, and help

cadenysd
Posts: 17
Joined: 22 May 2020 12:29

Re: AI vehicles variants

#8 Post by cadenysd » 13 Oct 2020 23:09

Thanks for your comprehensive reply, tinusman.
tinusman wrote:
13 Oct 2020 17:44
as you are new to modding, First extract de def.scs file in a map of your choce. (use scs_extractor.exe)
I am on Promods and tried extracting the def file but it did not work... Any ideas?

User avatar
Madkine
Posts: 3142
Joined: 08 Oct 2018 16:35
Location: Australia
Contact:

Re: AI vehicles variants

#9 Post by Madkine » 14 Oct 2020 02:01

If making a local mod, it doesn't need to be zipped. Just place the files in the mod directory.

User avatar
tinusman
Posts: 528
Joined: 11 Jun 2013 09:45
Location: driver`s seat

Re: AI vehicles variants

#10 Post by tinusman » 14 Oct 2020 10:00

cadenysd
Only scs files of game needs scs_extractor.exe
For mod`s use a pack/unpack prog. like winrar..

Madkine
As it was mentioned ^^^:
" it is posible to just put your def folder in the mod_folder.

most likely : make a .scs or .zip file
with re_reconizable name of your choise.zip"

only def folder : is not that reconizable
for sure when one`s making more mod`s later_on....
it wil become confusing.😌

Post Reply

Return to “Help center - player to player”

Who is online

Users browsing this forum: No registered users and 3 guests