CitiesSkylinesMods / TMPE

Cities: Skylines Traffic Manager: President Edition
https://steamcommunity.com/sharedfiles/filedetails/?id=1637663252
MIT License
576 stars 85 forks source link

TTL GUI fails to update light states #588

Open kianzarrin opened 4 years ago

kianzarrin commented 4 years ago

Background: In TTL when you stop the simulation, you have the option to see each step individually. as and example in the picture bellow I can see step 3 of my TTL Screenshot (136)

Problem: while I am viewing step 3 in picture above, if I start and then stop the simulation I will get the picture bellow which is wrong because some of the lights that are supposed to be green are now red. If I click on step 3 again it gets fixed. Screenshot (135)

We need to fix this GUI issue to update the lights properly. I think when we start and stop the timed traffic light we need to view step 1.

there is also a second related issue. If I am viewing step 4 of one stopped TTL and then click on another stopped TTL I will still observe step 4. if there is no step 4 then I observe nothing. I think when I click on another TTL I should observe step 1.

originalfoo commented 4 years ago

Ultimately we need complete new UI for the TTL.

However, if we're going to fix up what currently exists, would it be possible to make lanes highlight to the color of their associated traffic light? That would give a decent usability improvement, in addition to the bug fixes.

kianzarrin commented 4 years ago

@aubergine10 there are cases where the lane can go toward 2 directions but traffic light allows only one. There is not always match between traffic light and lanes

originalfoo commented 4 years ago

But doesn't each lane only have one traffic light?

kianzarrin commented 4 years ago

Imagine if the rightmost lane can go forward and right but the traffic light is green only for right.

It still possible to highlight the lanes associated with a traffic light thought.

Edit: I'll put a picture when I get to my computer

originalfoo commented 4 years ago

Could maybe do half lane (width wise) highlight in that scenario?

kvakvs commented 4 years ago

Code to render full lane https://github.com/kvakvs/Cities-Skylines-Traffic-Manager-President-Edition/blob/canvas-gui/TLM/TLM/UI/SubTools/LaneArrows/LaneArrowTool_Render.cs#L328