Speed limit gradietns and buffs/nerfs #668
Labels
enhancement
Improve existing feature
feature
A new distinct feature
Overlays
Overlays, data vis, etc.
SPEED LIMITS
Feature: Speed limits
UI
User interface updates
I spend ages fiddling with speed limits, only to have to redo them over and over as I keep altering my roads. It's also extremely time-consuming doing speed gradients due to all the back-and-fourth between signs on the map and the speeds palette.
Speed gradient (road) - modified click
Example: Slip road between motorway and roundabout. The motorway is 70 MPH, the roundabout is 30 MPH.
As cars approach the roundabout, I want them slowing towards 30 MPH.
Depending on slip road length (sometimes they are quite long) I don't want a smooth gradient from one end to the other, so I might have something like:
To make it generic (not just slip roads):
With this approach I can easily create speed gradient between two junctions, and I can choose where the gradient happens.
Possible key modifier:
Alt+Shift+Click
for "route gradient" (it compliments existingShift
= "apply to route" in speed limits tool)A variant could be
Alt+Click
(localised gradient) where user would create a gradient anywhere. For example, road is 50 MPH along many segments. I choose a differnet speed (faster or slower) andAlt+Click
segment in that road and it sets that segment to chosen speed and then gradiates speed in both directions to whatever the road speed is.Speed gradient (lanes) - mod option
Imagine motorway with 4 lanes. I set speed of motorway, both directions, to 70 MPH. I want outermost lane to be 65, middle lanes to be 70, innermost lane to be 75. So a
Modifier + Click
could take the current average speed of the lanes on each side and then apply the lane gradient to both directions (or something like that).This could just be a mod option that applies only to highways (it doesn't make much sense on city roads).
Speed gradient (slope) - mod option
I have some very steep inclines/declines where roads are going up or down a mountain and I often create slightly increasing speed on the way down, and decreasing speed on the way up. Not too much as drivers would just break/accelerate more, but just enough to make it look like the slope is having an effect on the vehicles.
Would be great to have a mod option that adjusts vehicles speeds on slopes:
Speed gradient (sharp bends) - mod option
I generally play on mountain maps so end up with lots of roads snaking down mountains or through valleys or along contour lines or besides rivers.
I like to have the sharp bend slower speed than the rest of the road, with the amount of slow-down depending on how sharp the bend is. And then a speed gradient on the segments either side of the bend. Aside from just making traffic behave more realistically, it also prevents emergency vehicles (when responding to emergency) from flying off the road.
Would be great to have a mod option that detects sharp bends and applies speed gradients to them automatically.
Regarding mod options
The user would set their speeds for the roads in usual manner, and the mod option(s) as applicable would buff/nerf those speeds.
There are already some features for altering speeds, namely:
I assume they are designed to just apply a buff/nerf to speeds of all roads/rails/etc on map, so not quite same as what the new mod options would do but maybe good place to look to determine where such buffs/nerfs can be introduced in to code.
For new mod options, doing calculations per frame per vehicle is going to be a laggy mess. So it would need to do those calcs whenever user places/changes roads or alters speed limits and cache the buffed/nerfed value alongside the users chosen value. Then the vehicle AIs would just use the buffed/nerfed value as basis for the speed of the segment/lane.
To keep data serialisation fast and small, only user speeds would be persisted in save game; the buffed/nerfed speed would be calcuated on game load depending on mod options.
Also, if mod options changed, the buffed/nerfed speeds would obviously need updating.
Related stuff
If we get good infrastructure for buffing/nerfing speeds, there's probably some other ideas we could revisit:
Alt+Click
?)The text was updated successfully, but these errors were encountered: