VictorPhilipp / Cities-Skylines-Traffic-Manager-President-Edition

Cities: Skylines Traffic Manager: Traffic President Edition
http://steamcommunity.com/sharedfiles/filedetails/?id=583429740
MIT License
147 stars 51 forks source link

Change default traffic light behaviour #200

Closed Sipke82 closed 5 years ago

Sipke82 commented 6 years ago

I think the main reason is why we need to setup timed traffic lights is because the default traffic light settings are a bit wack, as they allow multiple directions to enter intersection at the same time, causing collision points. It would be more logical if the default setting would not do that, and that way we can reserve the timed traffic lights for the more complex situations.

So for the default traffic lights it would be more logical to set up as: Lanes can go straight, left and right from one direction, the lane to the left can also turn at the same time because traffic won't hit each other. In addition add a step where pedestrian can pass, without being hit by cars.

This setup might be more logical as default traffic light setup.

AllegedlyLuca commented 6 years ago

A relevant bit of information on behaviour I've noticed in-game regarding lane arrows (and the behaviour of what left/right is on a traffic light, is that sometimes "left" or "right" also goes what you would expect to call "forward". Visual example as follows.

This is an intersection in my city of 163k, and it's pretty busy: image

On the 2by3 median-divided avenue going upwards, there's an LeftForward Right Right lane arrow system which I put in place. On that particular part of the road , "right" is any path drawn by a yellow line whereas Forward is identified by the green lines. It cuts off traffic coming from lanes intersection with the red arrows, as well as traffic coming from the other side.

I do agree with the step where pedestrians can pass without being hit though. More often than not traffic is moving slowly through non-timed lights because of pedestrians crossing all of the time.

originalfoo commented 6 years ago

What you're essentially after is a "default" traffic light setup that minimises crossing conflict points and also provides safe points for pedestrians to cross. So essentially it's a mathematical reduction of things like this:

conflict-points-of-a-typical-two-lane-four-way-intersection-or-driveway-sudas

Ultimately, the player should be designing their roads so as to reduce crossing and merging points wherever possible.

I'll create separate issue requesting tool for visualising crossing/merging/diverging points as that in itself would be incredibly useful.

VictorPhilipp commented 5 years ago

moved

brazenest-zz commented 5 years ago

I really want to see this feature. It'll be a game-changer for C:S and TMPE, because it would formalize a component of real-world engineering that is most conspicuously absent from vanilla imho. (This game is literally all about traffic management and paying attention to locations of things with respect to each other. How does C:S consciously overlook realistic traffic signal phasing?)

The key is to codify the NEMA ring-and-barrier phase diagrams (https://ops.fhwa.dot.gov/publications/fhwahop08024/chapter4.htm#4.2).

Those would address the majority of cases. Sure, the game prefers against dedicated turn lanes... so for now we exclude phases meant for dedicated turns. From that point, I want to see what the users report are the next common and/or exceptionally troublesome cases we should solve next.

I'm rusty on C(#) but I'm super willing to work on this feature. My cities need more traffic intelligence :)

brazenest-zz commented 5 years ago

What you're essentially after is a "default" traffic light setup that minimises crossing conflict points and also provides safe points for pedestrians to cross. So essentially it's a mathematical reduction of things like this:

NEMA phases (https://ops.fhwa.dot.gov/publications/fhwahop08024/chapter4.htm#4.2) are a formal expression of how to address conflict points and merge points in traffic signaling. We do need the deeper algorithmic solution for non-trivial cases, though.

One example: Dead reds. They occur notably when there's at least one direction of travel that is denied to all traffic moving through the intersection. If you technically could make a protected turn but your lane has no signal yet to permit it, you're at a dead red light.

To smartly eliminate that dead time, we could allocate greens in a way that looks like magic. The default could aim to achieve a balance of equal green time to every direction. Or we could run a greedy version in cases where we want to prioritize the apportionment.

Ultimately, the player should be designing their roads so as to reduce crossing and merging points wherever possible.

... which is why TMPE is there to help them along their journey of knowledge :)

I'll create separate issue requesting tool for visualising crossing/merging/diverging points as that in itself would be incredibly useful.

+++++

originalfoo commented 5 years ago

Thanks for the info! I'll copy this over to the new issue tracker: https://github.com/krzychu124/Cities-Skylines-Traffic-Manager-President-Edition/issues/5