Pavement Drive Assist Continued

by azaghal

Introduces a driver assistance system that autonomously follows paved roads, while maintaining a preset cruise speed if desired.

Content
11 days ago
1.1 - 2.0
15.1K
Transportation

i [DONE] Hazard road rank

2 years ago

Currently the lowest value are road markings but even those are positive, which makes sense as it will steer the autopilot back onto a road. This does mean that there is no way to have the autopilot avoid specific areas using tiles. For example: surrounding a big power pole with hazard concrete.

For this an additional hazard setting with negative values would be very useful, possibly with a string field for comma seperated tile names to be assigned that value.

2 years ago

Hello,

Unless I'm missing something, you don't really need them to be negative values. You could surround the power pole with a lower-priority tile compared to what is on the main road.

The main problem, though, is that algorithm might not be able to divert you from the said power pole unless you make it wide enough, and even then it depends on the car speed - the higher the speed, the less likely the car will be able to nudge itself around the lower-priority power pole.

2 years ago

It's admittedly as much a matter of principle as it is anything else. It feels like something that should exist, especially since right now hazard concrete and hazard asphalt have the same priority as the non-hazard variety.

2 years ago

Well... You have to keep in mind what the main focus of the mod was when it got created - mind you, I did pick up and fork the mod, but my understanding of the actual algorithm (the nitty-gritty details, I get the general concepts) for managing the vehicle direction is probably close to zero :)

The mod simply tries to keep the car in the middle of the road. Tile scoring is used primarily for separating lanes, and for avoiding the vehicle getting off the main road and onto the paved walkways etc.In fact, back in the day I tried using fancy lines around railway crossings, but had to give it up because the car would try to follow the main asphalt road, and would kinda go side-ways when it gets to those lines (hard to visualize, but it was pretty funny :) ).

One way to achieve what you mentioned would be simply to not assign any value to the hazard concrete. But I would not do this by default - for example I would often surround the rail with hazard concrete, and the algorithm would get confused once it reaches it (it might try to turn left/right in order to follow the main road).

As a side-note, the example you gave would be very hard to solve I think. Normally you need to design roads for use with PDA with a bit more width, and softer curves, otherwise the car cannot correct itself in time. You'll notice that as you drive the car is often not in the exact middle when it is going through curves etc (depends on its speed). Partially this is result of performance issues (since it operates on every tick to correct the vehicle bearing).

Speaking of which... Would it help if you were able to redefine weights for different tiles, as mentioned in the other post?

2 years ago

Thanks for the explanation, I'll play around with the values and see for myself how it works.
As for setting weights, I've branched the repo to add custom categories to the settings. I'm not good with Lua but I hope to push it this weekend if that's alright?

2 years ago

I'll continue the discussion in that other thread, since the two topics are kinda related, and the other one might be a bit more generic solution :)

1 year, 9 months ago

Hello again,

I think one of the features added to the mod should make it possible to achieve what you have requested, so I'll mark the topic as solved and lock it.

Thank you once again for all the feedback provided :)

This thread has been locked.