Choosing the AI's car upgrades

palindnilap

In existing mods where the car have upgrades, how can I have the AIs use specific upgrades ? I know it is possible for the modders because for instance GP79 automatically selects the car upgrades depending on the track chosen in order to reflect historic reality. But is it possible for the end user to select the AI's upgrades by tweaking the text files ?
 
Should I have posted that in the modding forum ?

I managed to find where it is done, but obviously I didn't figure it out right because it doesn't seem to work. Here is what I did :

In the mycar_upgrade.ini :

UpgradeClass = "MyUpgrade"
{
AIList
{
Model=4 // Should specifiy the 5th UpgradeLevel in the "Model" UpgradeType ?
}
}

In the mycar.veh :

Classes="XXX,YYY,MyUpgrade" // Makes the MyUpgrade class appear in the opponent selection box (not sure if that really refers to an UpgradeClass?)
AIUpgradeClass=MyUpgrade // Tells the AI to use the MyUpgrade UpgradeClass

When I select the MyUpgrade class, the AI still uses the default car, at least visually (the upgrade is visually different when I select it for my car).

What did I miss ?
 
OK, I figured out one way to do it :

In the same directory as the upgrades.ini file, create or modify a file named TrackConfigsBase.ini with the following lines :

"*":
Model = 4

One can even specify a different upgrade for a specific track by

"TrackName":
Model = 5

Works like a charm, rFactor configurability rocks but the documentation is a bit patchy...
 
Last edited:
Oh, I have the same problem! But what I see you are doing is make all AI cars use the same upgrades..

Would it be possible to make each AI car have different upgrades, for example different rims? I thought of using the AIUpgradeClass=, but what I don't like about it is that it is visible to the player.
 
Oh, I have the same problem! But what I see you are doing is make all AI cars use the same upgrades..

Would it be possible to make each AI car have different upgrades, for example different rims? I thought of using the AIUpgradeClass=, but what I don't like about it is that it is visible to the player.

I can specify different upgrades for each vehicle. Normally each vehicle is in its own directory, with its own mycar_upgrades.ini. So in all those directories you can have as many TrackConfigsBase.ini as you have different cars.
 
YES, I made it!! But there is a problem.. All my cars are the same and I use the same upgrade.ini for all, but I want each AI to use different parts.

In this way you told me, I have to copy the "global" .ini file to each car folder (it doesn't work only with the trackconfigsbase.ini unfortunately), and now it makes a mess, and I am afraid how it's gonna be handled in multiplayer when other players start copying teams and ini files..
 
I figured out the best thing for my case would be to use the classpackages and then tell AI to use them in .veh

But if I just could hide classes from upgrades, THAT WOULD BE PERFECT!
 
I think I've found a way how to do that too... Duplicate .veh files and then make one veh no_ai and one AI_only, then they can have two different upgrade.ini-s and it effectively hides the class packages to the player
 
Sorry, I misunderstood your request, thought you were asking about one upgrade by car type, not by car item.
Glad you could make it anyway. How do you specify a class package in the .veh ? I had tried that before and wasn't able to make it work (see code above).
 
Is there a way to add to the existing upgrade.ini file a way to have AI to use the cars from those that I have purchased, including upgrades purchased for each car? My upgrade.ini file includes upgrades for aero downforce including several different devices (no spoiler devices is the base and different choices affect downforce etc in HDV file), a couple transmission options, as well as some graphical options (wheels etc). It works as intended, however, the AI are always the base model (without any upgrades).

It obviously is no big deal to go through and purchase each car and purchase different upgrade options to set up potential field.

But how does one get the AI to select/use only the cars - as owned (by player) - including any upgrades (as purchased for each car)?
 

Back
Top