The online racing simulator
#1 - janm
How to make offline racing more fun
Hi, everyone.
I've been playing lfs for over a month now, mostly offline, due to not having internet connection at home....

Well, everyone who is a fast racer, say 1.32.xx at Blackwood, knows Ai PRO aren't competitive at all, coming over the finish line 30,40 seconds behind, a minute even.

So, i thought about how to make ai better...And came up with this idea:

Say, you are playing online( 5 lap race at Bl for example) and you finish in 7:52. The first one comes in 7.49, second one in 7:51,third 7:52 and others somewhere around your time. You save a replay of this specific race you thought was quick. You would probably like to go as fast as the fastest racer and i think the greatest way of learning and striving for that time would be to OUTPUT specific racers' data for this race ( the driving path, braking points, like a raf. file ( i think this is the extension used for outputting lap data for AFS).
Then having recorded the driver's race data, assign this data to various AI cars and have a great, tight offline race against FAST laptimes and racetimes of the fastest racers outthere..

I'm looking forward to your feedback.

p.s.: i apologize, if this was already started somewhere, but it just seems a great idea and i wanted to know what you guys think about it. Don't know how difficult it is to make it reality, though, since i'm not a programmer..

Jan
The AI need to learn how to give the racing line up before I let them on track again !
Quote from janm :...i think the greatest way of learning and striving for that time would be to OUTPUT specific racers' data for this race ( the driving path, braking points... Then having recorded the driver's race data, assign this data to various AI cars...

Great idea, Jan!
Jan the AIs learn if you let them race. Give them 100% of fuel, a full field of AIs and just let them race. Repeat the rpoces. Give them your set. They will be faster form a lap to lap.
#5 - Jakg
yep, they learn, but the fastest my AI will get is 1:37.xx ,theyve reached their limit
#6 - janm
Quote from Primoz :Jan the AIs learn if you let them race. Give them 100% of fuel, a full field of AIs and just let them race. Repeat the rpoces. Give them your set. They will be faster form a lap to lap.

Yeah, i've heard of this.
But this would be a much longer process, wouldn't it?

Imagine, if you could just assign the racers' race data to ai...
It would be like driving in a replay...But the ai should still have some ''logic'' predefined in case off crash or running off the track, to recover...

I guess it's quite a complex thing...
AI takes FZRs and you take UF1000. Problem solved.
#8 - Vain
Retrieving the driver's "data" or "style" from a replay is a very complex thing, because you can't discribe it mathematically. You could propably feed the best lap's velocities and positions into the AI-path in LFS, but the result would hardly be the same.
I'm tempted to talk about artificial intelligence and neural nets and stuff, but I will show mercy and skip that part.

But here's a better solution. When I want to race the AI I give the AI my setup and then modify my setup to be slightly worse (-> gearbox) or use an inferior car. AI XFG versus me in the XRG is a good combo, f.e.

And a last one on the AI-drivers: They drive cleaner than most people on public servers. I have no problems with sharing the racing line with an AI driver through several turns. No contact, just great driving.

Vain
#9 - janm
Quote from spankmeyer :AI takes FZRs and you take UF1000. Problem solved.

:doh:
There's one problem with the idea:
AIs driving exactly the same line as someone else will make weird things if they are influenced by any other object in any way. Means, if you have 10 cars that drive from another spr, their lines may never cross each other. This is quite impossible :P

Have you tried to give the AIs your setup? or are they driving default one? Just take a look at the settings (Misc iirc).
#11 - janm
Quote from ORION :There's one problem with the idea:
AIs driving exactly the same line as someone else will make weird things if they are influenced by any other object in any way. Means, if you have 10 cars that drive from another spr, their lines may never cross each other. This is quite impossible :P

Yes, i didn't have that in mind, but now i see it's a very complex thing to calculate...Anyway, the online aspect of the game is great...It's just, i have to play it offline more, because of not having internet connection at home yet...
#12 - Goop
Racing in a actual replay (a close scratch-race, an historic LFS race, or a league race you couldn't make but have the replay to...) would be very cool, but noone wants to be a ghost car...

Perhaps, a simple-ish way: You've affected the race, and knocked a car off. At the end of the lap, the car reappears where it should rightly be in the replay

Could that work? Could a replay function like that?

(Either that, or just grab your AI, and stick some passengers in your car... or see if you can pass them all cleanly within a lap )
You could give yourself a weight handicap (extra fuel or passengers). The downside is that you can't drive in the same way as you would in an online race, because a heavier car can't take turns at the same speed.

IMHO it would be better if the AI cars got a "performance bonus", e.g. grippier tyres. That would be unrealistic, but it's a compensation for AI's lower ability to drive the car at the limit. Of course, you should able to set the amount of bonus in the options screen.

But first, I'd like to AI to be more polite. All too often I've be pushed off the track because an AI car bluntly took the racing line -- right where I was, having almost completed overtaking it.
#14 - Vain
Quote from wsinda :But first, I'd like to AI to be more polite. All too often I've be pushed off the track because an AI car bluntly took the racing line -- right where I was, having almost completed overtaking it.

The AI has to learn overtaking before it can do that. So give the Ai some practice and it will know that driving below 0 inches apart from another car is bad.
My suggestion: Mix RB4s with 1 or 2 UF1s on AS Cadet for some 100 laps. After that the RB4-AIs should have understood what overtaking is about.
And by the way, the overtaking-experience is carried on to other tracks. So after that the AI can evade other cars not only on AS Cadet, but also on the other tracks and in other cars. But it will have no knowledge *where* overtaking is safe and will attempt overtaking in stupid areas sometimes. But real people also do that very often.

Vain
got the same problem, no interent for online races, and silly ai. but whatever, i spend quite some time doing either hotlaps or adding faster cars to the field. the ai seem to not improve their speed enough to keep up.

the only real solution i see to this issue is to get an internet connection. i'm working on that. and by the time the ai has been improved i probably won't care anymore

FGED GREDG RDFGDR GSFDG