The online racing simulator
Test Patch D4 (now D48)
(704 posts, closed, started )
I think i forgot to mention that it was on PRO skill level as they do drive a little bit faster. On easier levels they drive very slowly so obviously they wont run wide as much or at all.
Quote from r3zp3k7 :What if they got the path wrong in Patch D37 and now retry the same path in D38? Maybe a fast fix for this could be to delete the .knw file(which was generated in D37) and make Ai recalculate a new path(in D38)?

Path generation is the same in D37 and D38. Only if the mod changes (width, power, etc) the path would be generated differently.

They don't learn after the initial generation. Every race works out differently because of randomised reaction times at the start. Also if wind is enabled that would add variation.
I tried out a configuration with formulas and bikes. Its a killing spree, formula Ai's are really aggressive.

I uploaded the replay. Check the start.

Edit: BTW. Overall Bike Ai's are doing really well in my eyes. Especially for a newly added feature in a beta patch. Nice work!
Attached files
spr-killing-spree.rar - 1019.5 KB - 120 views
D39 is now available with AI improvements. I recommend deleting the bike AI paths created in test patches D37 or D38 (since 11 September) as the bikes now have a narrower theoretical width. Existing paths will still work but new ones will allow the bikes to use a bit more of the track.

Bike AI:

Smaller assumed width (closer passing distance / better lines)
For best results, delete bike knw files from data\knw folder
(generated since 11 September in D37 or D38 test patches)

Overtaking AI: (all vehicles)

Various improvements to improve the overtaking decisions
There should be fewer dangerous overtakes in braking zones

https://www.lfs.net/forum/thread/102117
Wow Scawen, you're on fire, tnx very much for all of these nice AI updates Smile
Some things I notice in D39 (after generating new paths) and you can check them in the attached archive file:

1.Mixing different types of vehicles is deadly
2.Trucks/Buses drift or go outside track at high-speed corners + they steer really fast right/left when overtaking and they lose control
3.Bike Ai seems fine now

I uploaded another SPR with a mix of vehicles and three screenshots, just if you are curious to see what happens. It's a killing spree, but maybe this is the perfect state as it could get at this point.
Attached images
lfs_00000991.jpg
lfs_00000992.jpg
lfs_00000993.jpg
Attached files
spr-killing-spree2.rar - 3.1 MB - 116 views
I hope the improvements are all good. Yesterday's overtaking improvement should apply to all AI.

I assume that mixing different vehicle types, and AI driving large vehicles, are no worse in D39 than they were in any other versions. If anyone can show that anything has got worse, I'd like to know about it.

I suppose the code for AI to avoid collisions is built on assumptions that the other vehicles will follow similar lines and be at similar speeds, as they would in real racing. The old LFS tyre physics is stretched to the limit (or should I say beyond the limit) with bikes and heavy vehicles. At this point I don't think it's a good idea for me to spend any time trying to make AI drivers work any better with the old tyre physics. Instead I should get back to finishing the intermediate incompatible update with improvements for mods.

As mentioned, I would like to hear if any AI behaviour has got worse, or any more specific and repeatable issues with the new bike AI.
-
(Viperakecske) DELETED by Scawen : irrelevant
-
(Flotch) DELETED by Scawen : irrelevant
-
(johneysvk) DELETED by Scawen : irrelevant
-
(Viperakecske) DELETED by Scawen : irrelevant
Here's a scenario I was unable to replicate in 7D: AI may stall at starting line. It seems to be related to the random reaction time mentioned earlier (it does not happen 100% of the time). The AI may be too aggressively trying to avoid collisions during the standing start.

This also could be related to the mod (but sub 500 hp with road_supers isn't exactly a rocket ship). I did not try it with other cars.
Attached files
slow_WE2_F1A4EF.spr - 90.5 KB - 120 views
aoeu.spr - 100.4 KB - 114 views
Thanks for that, I was able to reproduce it in a deterministic game setup. It turns out a bit of an obscure bug that could sometimes cause AI to hit the brakes if they are slightly faster than another other car, but the other car is accelerating.

It seems like an old bug that has been there forever, but maybe it became slightly more likely to happen in the latest patch. It wouldn't be limited to the start grid, so maybe there will be some times out on the track when a car would have braked momentarily for no apparent reason.

I'll release another test patch with this and probably another couple of updates either today or tomorrow.


EDIT: Unfortunately, this bug fix hasn't magically fixed the issue where a faster car gets stupidly stuck behind a slower car, all the way down a long straight. Uhmm
AI seems to wobble it's bike on certain tracks. It's like changing line all of sudden. ( Although may happen with cars too )

Most likely on AS4 and KY3 ( when entering track from pitlane )
I just found out, s_plate texture somehow bugged on D39

the number plate somehow duplicates AI s_plate with mine, in this case, AI 13, as you could see from the first 2 pict I attached below.

anyway, I do love how now AI could be set on open config track, so I could set some scene for my upcoming mod like how I did on 3rd pict Big grin
Attached images
lfs_00000171.jpg
lfs_00000172.jpg
lfs_00000170.jpg
Quote from Scawen :Victor has rebooted the server in Japan so hopefully it should run smoothly again.

At least, I can start a host in Japan and join it now. I haven't tested mod redirecting.

Works fine now, thanks Smile
I feel like the AI in D39 is generally slightly faster, or at least doesn't brake as easily when in close proximity to players or other AI (it still does, especially when they're on the outside when exiting a turn, but less often).
However, I found 3 issues with them:
  • At the start of the race, most AI have a very poor launch, as they brake for no apparent reason and also swerve quite a lot (see XRR replay).
  • Some cars can end up in a massive pileup and stay there for a while for no apparent reason (see XRR replay).
  • They tend to "move under braking", or at least AI FBM do, especially if you're on the outside and force them away from their line, they tend to move to the outside and push you (see FBM replay, where I try to force AI out of their standard line, especially at T1 on lap 3).
Note: I also tried clearing the contents of the knw folder, I did not notice a significant difference, but both replays were recorded after doing so and letting the game create new knw files.
Attached files
BL1_XRR_pileup.spr - 1.8 MB - 115 views
BL1_FBM_AI_lines.spr - 3.1 MB - 125 views
Quote from ivancsx :I just found out, s_plate texture somehow bugged on D39

the number plate somehow duplicates AI s_plate with mine, in this case, AI 13, as you could see from the first 2 pict I attached below.

anyway, I do love how now AI could be set on open config track, so I could set some scene for my upcoming mod like how I did on 3rd pict Big grin

As for comparison, I had attached this conditions when I'm still on D33, and after I just downloaded the latest, D39, the pronlem exist
Attached images
Screenshot_20230916-145703_Discord.png
Quote from ivancsx :As for comparison, I had attached this conditions when I'm still on D33, and after I just downloaded the latest, D39, the pronlem exist

this has been for years my dude, like years years, even before mods.
Thanks for the feedback. I've released D40 which should solve some issues and hopefully doesn't introduce serious problems!

Quote from UnknownMaster21 :AI seems to wobble it's bike on certain tracks.
...
Most likely on AS4 and KY3 ( when entering track from pitlane )

I think wobbling is worse on some bikes than others. I tested with 6 bikes on the tracks you said, and the only one that really wobbled was the Mosquito (with passenger). I found it hard to improve wobbling when I looked into it the other day. I think that will have to wait for the new tyre physics. But if there is a situation where many bikes wobble, I'll have a look.

Quote from Bokujishin :...I found 3 issues with them:
  • At the start of the race, most AI have a very poor launch, as they brake for no apparent reason and also swerve quite a lot (see XRR replay).
  • Some cars can end up in a massive pileup and stay there for a while for no apparent reason (see XRR replay).
  • They tend to "move under braking", or at least AI FBM do, especially if you're on the outside and force them away from their line, they tend to move to the outside and push you (see FBM replay, where I try to force AI out of their standard line, especially at T1 on lap 3).

The first item, is probably that reported by bobloblaw above, which should now be fixed.
The second item, I noticed this, it was a newly introduced bug, now fixed.
The third item, I'm not sure about. It sounds like something that could have always been the case. Or do you think it's something new?


Changes in D40:

- Safer bike overtaking distances (hopefully not too far)
- Consideration of barriers more dependent on current offset from ideal line
- Distance to vehicle ahead considered dangerous, now depends on length of vehicles
- Much more likely to attempt overtake, when previously stuck behind a slower vehicle
- FIX: Could brake if slightly faster than another car but the other car is accelerating
- FIX: Sometimes applied brakes and stopped on track next to another vehicle

Download: https://www.lfs.net/file_lfs.php?name=LFS_PATCH_7D_TO_7D40.exe
Quote from Scawen :The first item, is probably that reported by bobloblaw above, which should now be fixed.
The second item, I noticed this, it was a newly introduced bug, now fixed.
The third item, I'm not sure about. It sounds like something that could have always been the case. Or do you think it's something new?

The first two items seem to be fixed indeed. Third one I'm not entirely sure actually, at the end of the back straight in BL1 they swerve slightly to the left as they enter the braking zone, but that's part of the racing line.

The other adjustments look pretty good to me, I think racing against AI cars is much more interesting now. Hopefully it can be improved further once the updated graphics and physics are out of the way.

Also, I just tried having a race with 8 FXR, 8 XRR and 8 FZR on KY2, and maybe it's because of the latest changes, but there was a big crash exiting T1, probably because they were a bit too eager to overtake each other. I'll test some more tomorrow.
Quote from superlame :this has been for years my dude, like years years, even before mods.

I think I havent experience this before, but well, I'd fixed it now by shortened the areas of s_plate, quite unfortunate we need to adjust it exactly as the text shown, no excess area allowed
I managed to break AI (get it stuck in a pile Big grin). They do drive better now, still making some bad overtakes that causes them to go wide and offtrack but a lot less than before. Also it would be nice if AI used random color suits though.



I bet AI could drive slightly faster (and lean more) with my bikes as they don't wobble on corners. Since they collide with other bikes rather often anyway why not increase their speed, for PRO skill level, other levels could be slower like it is now.
Good job man, I hope the game gets better. :]
I have two installations of LFS, one with patch 36 and the other with patch 40, and I did the same races.

1) Against 16 AI in FZ5 equipped with Slick (test mod).
No notable changes. Perhaps fewer collisions at blocking points, especially after the first ISSC hairpin.

2) More interesting, 16 AI, SLX180 TYPEX MOD (Smile excellent ! https://www.lfs.net/files/vehmods/35D799).
Very chaotic start with patch 36, with a lot of collisions in the first turns, then many exits from the track with a lot of AI in the grass.

With patch 40, normal start, slowdown without collisions at the first turns. Normal race, AI on the track. Less contact with the AI when overtaking.

In summary (for a very quick test) impossible race with patch 36. Pleasant race with patch 40.
I can repeat the same protocol (or improve something?) during my next sessions, if this is useful.

Smile For me and for now, it's much better.
Bokujishin, Drifteris and Avraham Vandezwin: Thank you for the AI testing and results.

It sounds good so far. I'm sure most of the changes must be for the best. It's still possible that there are some negative side-effects.

By the way, you don't need a full separate installation to compare D36 and D40. These versions are compatible so it's fine to use renamed exes in the same folder.
Tested D40 and noticed several things. Some are related to this test patch and some are not:

Unrelated to this test patch, but found when viewing replays:

1) Possible bug when renaming a replay:

If I try to rename a replay on LFS by simply changing a letter from lowercase to uppercase (or vice-versa), it doesn't allow me to do that. Instead it says that the "Name is already used".

For example: I had this replay I've attached originally named "KY1_MotorBikeTest_Cannot_Reset" and I tried to rename it "KY1_MotorbikeTest_Cannot_Reset" where the only difference in that name is it's named "Motorbike" and not "MotorBike". However, since that was the only change, it didn't allow me to rename it until I renamed it first by adding/removing a character and then renaiming it again.

I understand you can't rename a replay to a same name that other replay already has, but it shouldn't do that when you're simply changing a character from lowercase to uppercase or vice-versa. Is this on purpose that you can't do this in-game but you can do this when renaming those files in File Explorer?

2) Question about F11/F12 window when trying to view a single player replay:

Is there any reason why I cannot view F11/F12 menu when viewing single player replays, but I can in multiplayer replays? Because of this, I can never take a refresher from a single player replay when I want to take a look at their tires, restriction or skill level.

Caveats about AI's:

3) Bug on Westhill National Reverse and International Reverse with AI:

It seems like it's completely luck whether they can successfully enter a pitlane in Westhill National Reverse and International Reverse or not. When they enter pitlane, they usually make a weird "snake move" and may spin off and in worst case, get stuck at the wrong side of the pitlane. This happens especially when AI's are driving faster cars.

- I've attached a WE2R-replay about this one: there are 20 PRO-level AI's, each one having different standard LFS car. Take a look what happens to BF1, FO8 and XRR when they try to enter a pit lane. Also take a look what happens to LX4 and MRT when they try to exit their pitbox and UFR is in front of them, since that is related to another caveat mentioned below.

This "entering a pitlane" bug doesn´t seem to happen on other tracks aside from these two.

4) Caveat related to this fix Scawen:

Quote from Scawen :
- FIX: Sometimes applied brakes and stopped on track next to another vehicle

This bug seems to be partially fixed. I'm saying partially since this fix doesn't seem to apply in pitlane and pit exit lane? Ever since 0.6K was released, AI's have become way too careful in pitlane due to this:

Quote :Now avoid ramming other cars when in the pit lane or lap of honour

What this has resulted that if AI driver tries to enter or leave a pit box and another vehicle/object is stooped on that pit box or one immediately before or after, that AI will stop completely, because it's too scared to enter/leave that pit box. Same thing happens if another vehicle/object is stuck in pit lane.

I've attached a SPR named "KY1_FootballTest" about this: these 20 same AI's are again racing in Kyoto Ring. But this time, I'm also participating as a football. I'm deliberately in the pitlane to prove that AI's do get stuck, if something is blocking their path in the pitlane.

This is happening on every track that has pit boxes.

5) Problem with AI's using bikes:

This applies to all AI's that are driving vehicles which have motorbike gearbox (like MRT5 and motorbikes). If you have disallowed car reset and they are near an object or another vehicle, they will very soon shut their engine off, thinking they cannot get anywhere past it since they can't drive in reverse. If they can reset their cars, they will reset their car and try again. Other vehicles don't have this problem since they can always reverse and try again.

I've attached two replays about this, one where resetting a car is disallowed and another where it's allowed. You can see what happens to them when they face that football on pitlane.

This and the previous caveat on D40 seems to happen in pitlane and also on pit exit lane, but weirdly enough, not on pit entry lane. If they're on pit entry lane, AI's just ram that object/vehicle out of the way.

I'm saying this has been partially fixed because I tried this with 0.7D and there, AI's got stuck also on pit entry lane.
Attached files
KY1_MotorbikeTest_CanReset.spr - 1.1 MB - 109 views
KY1_MotorBikeTest_Cannot_Reset.spr - 399.1 KB - 127 views
KY1_FootballTest.spr - 7.5 MB - 108 views
WE2R_PitlaneTest.spr - 16.9 MB - 109 views
Quote from Scawen :It sounds good so far. I'm sure most of the changes must be for the best. It's still possible that there are some negative side-effects.

Not sure if it's a side effect of the recent patches or not, but as tankslacno mentioned, AI have some difficulties in the pits, and this is exacerbated by their tendency to all pit on the exact same lap. Some variation in strategy would be nice, even if random, although I guess that's out of the scope of this patch.
Also mentioned by tankslacno, the "snake move" was rather common in previous test patches when they would try to overtake, it feels to me like they're driving with a PID constraining them to the racing line, and changing line or jumping into/out of the pits makes for a very brutal transient that they can't save.

The overall experience with AI racing is much more interesting none the less, but if I can bring up one more point, it would be their blindness to obstacles, as they make no effort whatsoever to avoid cars stranded in the middle of the road, or bikes lying on the ground.
Thanks for the feedback. Some more AI improvements are coming, I guess tomorrow.

Quote from tankslacno :2) Question about F11/F12 window when trying to view a single player replay:

Is there any reason why I cannot view F11/F12 menu when viewing single player replays, but I can in multiplayer replays? Because of this, I can never take a refresher from a single player replay when I want to take a look at their tires, restriction or skill level.

I looked at this and also wondered why these views are not available in a single player replay. Uhmm

I think it would be simple enough to enable these views, treating all cars as if they are remote cars, as in a multiplayer replay.

Can anyone think of a reason why I shouldn't enable an MPR-style view in F11/F12 when watching an SPR?
This thread is closed

Test Patch D4 (now D48)
(704 posts, closed, started )
FGED GREDG RDFGDR GSFDG