-
Notifications
You must be signed in to change notification settings - Fork 85
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
An option to enhance the behavior of the Can Cross Lanes road asset flag #1220
Comments
I'm willing to actually do this work. I know what I'm doing, but I would need guidance in how CSL modding works and where the right pieces are to make this happen. |
Cool idea. I also have a mod that can detect if there is median based on mesh. But I think your idea is good enough. |
Interesting. Does this mod achieve what I'm looking for, and is it compatible with TM:PE? I think doing it based on lane configuration would have advantages. It's nice not to be dependent on the shape of the road surface (assuming that's what you mean). |
If this gets implemented (I hope so, love the idea - see tagged issues above) note that some roads have very strange lane configs, for example an empty lane that spans entire width of road, or empty lanes that just seem randomly placed... Would possibly need some way for user to interact with the lanes of a segment to indicate certain lanes should be ingored, etc. Width of lane would also need investigating, for example I suspect the UK roads with cat's eyes use prop lanes between each vehicle lane to place the props along the road; those should still be crossable. |
@aubergine10 |
I don't have much to add to what @aubergine10 already said. Many tried, everyone failed. It's way more complicated than you might think. |
#243 was a past attempt, likely worth looking at in any future attempt |
Regarding Qeens Blvd image in OP, how do we keep traffic out of the outer access lanes unless it's planning to park/deliver there? Otherwise there will be loads of traffic using those lanes as a through-route just like all the other lanes. Maybe an "redsidents/deliveries only" vehicle restriction, or make the lanes appear congested so pathfinder generally tries to route around them? |
@kianzarrin does this new mod cause issues with your median detection? curb height adjuster |
I thought of that too |
Does speed limit help with this? The speed limit will be lower on the local roadways than on the express roadways. It could be set quite low (within reason) if that would help.
This won't work because the local roadway doesn't really work that way. For example, the express roadway may not allow a right turn; rather, you would have to take a ramp to the local roadway and turn right from there. Also, some minor cross streets only connect to the local roadways.
Sounds kludgy. ;-) |
Slow speed limit would certainly help, and with the new speed limits UI that's currently being tested it will be vastly easier for users to set/change default speed limits of lanes (eg. so speed limit approach would work well for existing assets). |
Thanks for the feedback, everyone! I want to avoid scope creep. It would be cool if this could solve all existing median-related problems, but I already suspected that it was just as likely to create problems as to solve them. That's why I proposed it as an optional setting. This discussion, and #243, have shown me that there are too many things that could go wrong. This feature won't be much good if no one can enable it because of the problems it causes. My gut is telling me not to do it this way. That leaves us with a couple of alternative options that I can think of: Option 1: Just use the Lane ConnectorIn this case, the lane connector would need a flag on the node saying that it applies to all vehicles (including emergency vehicles and anything else otherwise exempt). And for usability, a shortcut to create sensible lane connections that don't cross non-vehicle lanes. Option 2: Devise a way to configure the lanes on the road asset itselfThis is by far the better solution, but I already know enough to know that it's not an easy one. The mods and assets I've seen suggest to me that we can't add our own properties to a road asset. I hope I'm wrong about this, because that would be the logical and straightforward way to do it. Assuming that is not an option, I suggest that TM:PE add two dummy props at runtime: A Lane Movement Control prop, and a Delayed Lane Usage prop. Ideally these would get their own category in the Asset Importer dialog, but they could just be in the Roads category if necessary. They would render nothing, but TM:PE could detect them and use their settings as follows: Lane Movement Control
Special attention to how this interacts with left-hand driving may be needed. Delayed Lane Usage
This prop would also be great for center turning lanes. |
One more thought: It would probably make sense to automatically apply the Lane Movement Control prop's effect at runtime to the inner lanes of any road asset where Can Cross Lanes is unchecked. That way, the same logic can be used on all roads. |
Adding props carries its own problems - eg. what if road is moved using Move It, or bulldozed, etc... props need to respond accordingly. To avoid changes to pathfinder, the goal would be find some way to semi-automate (user would still need to choose where traffic can join/exit) lane connectors and speed limits in relation to medians and the distinction between local/regional traffic lanes. I think Continues Junction Median and Adaptive Roads mods already cover some of the groundwork for what's required; namely being able to have custom road flags and toggle medians on/off. |
The idea for the props is that they are dummies, not rendering anything, which the person creating the road asset would add to the appropriate lanes to flag them as requiring special treatment by the pathfinder. They'd just be attached to the road asset itself, ready to be detected and acted upon by TM:PE, so moving and bulldozing wouldn't be an issue. When placing the roads in your city, you wouldn't even be aware of them. You would just know that the medians are honored and the local roads used appropriately, and you would hopefully learn from the road asset descriptions that you should set up ramps using the Intersection Marking Tool, TM:PE's lane connector, and Node Controller Renewal. If this ever sees the light of day, I'll be creating guides and maybe YouTube videos for road asset creators and city creators. I'll look more closely at the mods you mentioned, but I thought they were about rendering in response to TM:PE rules. |
Rather than props, something like Adaptive Roads custom lane flags would probably be better approach; asset authors can specify flags, then AR mod lets users toggle the flags in-game, but the flags can also be read by mods. Flags can be used to toggle meshes, props, etc. - Kian will be best person to clarify that. Looking at the road in google maps, it's a nightmare... There's so many junctions/filters to the central lanes that their whole purpose - to bypass local traffic - is utterly defeated. There's a major junction every 2 blocks, and often a filter junction between every major junction lolol. Would there need to be multiple prefabs, eg. one (two?) with the filter lanes, one without filters? How are things like stop lines - but only on the filter lanes - going to work? Currently stop signs in CSL (and TMPE) affect all lanes in specific direction on the segment. |
It's more about separating the thru traffic from the vehicles that are picking up and dropping off or trying to parallel park, the pedestrians, bicyclists, etc., rather than actually eliminating cross streets. The stop signs (there are stoplights in some cases too), if achievable at all, aren't something I'm looking at doing initially if ever. On the real street, they're a relatively recent addition. You can see the remnants of the old ramp design in the pavement structure. The ramps, or filter lanes, would be at nodes. The lane connector would govern the vehicle movement, and the Intersection Marking Tool would paint it. Here's a proof of concept I did: My objective isn't a perfect recreation, though I think that's what the person who put the idea in my head was hoping for. I just like the general concept. |
Ok, to clear up one thing because I see one thing confuse a bit:
|
I'm going to step back from this and look for other smaller tasks to familiarize myself with modding Cities: Skylines before trying something this extensive. I still want to come back to it, but I doubt that I would try to implement it as originally described. @aubergine10, since you liked the idea so much, does that mean it's all yours? 🤷♂️ |
See #1223 which gives rough idea (which may or may not be valid) of what might be involved - median detection, creating/associating lanes with medians, ordering lanes by position on road, grouping lanes between medians, etc. In addition to that, UI would need updating, eg. lane connectors/arrows would need to limit to connectable lanes. |
@aubergine10
Not that I know of. |
@aubergine10 can we use None lane as median at middle nodes? what about vertical offset? what about mesh outline?
|
|
What about lanes (including pedestrian or bike lanes) that are at a different vertical offset? Do you know of a scenario where this would not indicate a median? |
@aubergine10 but is there any |
If vertical offset is an indicator of median, I think the lane type won't matter. But in this case there would need to be a limit--a range in which a median is indicated. Otherwise elevated tracks could become an issue in some cases. (I believe most of them have their supporting structure directly underneath so it would function as a median, but the supports could be off to one or both sides.) |
@Elesbaan70 what is supports? |
The structure that holds up (supports) the elevated track -- pillars, walls, etc. |
Yes, sometimes
Not that I am aware of. But... As you know, creators use existing road as template. If that road has lanes they don't want, they will get rid of them in various ways - eg. just removing meshes/textures, setting It is possible (but not visible to end users without detailed invetigation) that there are road assets with raised lanes that used to be a median, that the creator just unmeshed/textured etc - from creator and user perspective, the road works. From our perspective we now have something that looks like median that isn't a median. In this situation, is that "possibly median" over actual road vehicle lanes? If there is already traffic lanes driving "under" the "possibly median" then it's not a median from creator/user perspective. Other random thoughts:
|
My goodness, I was clueless when I created this issue! What led to the conversation being reopened was this: But as someone else pointed out on Discord, it's not really a good example of the median detection problem, because the cars are also crossing opposing traffic. The routing manager ought to be smart enough to prevent this when Can Cross Lanes is disabled, and I'll probably have a look at it myself at some point. But I will eventually return to the Queens Blvd style roads, and would like to see some kind of solution to the median detection problem. |
|
#1220 (comment) |
I can't remember which asset it was. Next time I'm in game I'll test all the workshop roads I have - hopefully I still have it subscribed. |
As an interim measure, could we determine how many oncoming lanes a vehicle is trying to cross? If more than 1 lane, it should be treated as highly dubious.
Correct, but many asset creators have no clue what most of the properties do, especially if they haven't discovered sites like cslmodding.info. It's often case of just fudging a template asset in to something that works for them, then share to workshop. And most road assets never get updated after being published. |
This probably needs to be moved to the displaced lanes discussion, but I think a lane change across any oncoming lanes is dubious. For purposes of lane changes (not turns/connections), I'm thinking it should work something like this:
I'm all for accounting for badly designed assets when we can, but we have to draw a line somewhere. |
Yes, but what does "can cross lanes" mean to someone who does't currently know what it means. While the term makes sense to us, it doesn't necessarily make sense to everyone else. Do most users know what "enable bending nodes" means?
If it's vehicle cutting across oncoming traffic to change to different origina-direction lane via a non-junction node, then yes, that is weird af and probably should never happen. If it's making a delivery to building on other side of the road, then it's fairly common in UK and much of Europe.
I always thought the flag was about "can deliver to building on other side of road" / "can leave building and go directly to other side of road to start journey". |
We're talking about asset creators, not just anyone. Assuming that no one knows how anything works will cripple any future development.
Over a median? That's what we're talking about. That's the proper use of the Can Cross Lanes flag.
Yes, but bear in mind that this was CO's solution to the median problem. Rather than trying to work out the existence of an actual median, they made crossing oncoming traffic the determining factor, and put a flag on the road asset to indicate whether this should be allowed. So displaced lanes are a new use case they had not anticipated, but it still fits. |
@aubergine10 @Elesbaan70 All the issues you raised are all interesting and valid points. But none of them are serious enough to abandon this task all together. Even if we cannot detect all medians, detecting some medians is an improvement that is easily achievable. At least it would make it possible for asset creators to make TMPE friendly roads. What would be a serious (but even then I still don't think its a blocker) obstacle is a false positive. I have not seen any such example. I think detecting medians using elevated None lanes is an easy yet effective phase 1 for this issue (you can do 80% of the work in 20% of the time). Currently no one can create assets that prevents cars from crossing medians. After completing phase 1 at least informed asset creators will have a way to solve this problem. dealing with uninformed/old assets can come in later phases of this operation. it probably would take me less time to write the code than to discuss it!!!! |
yes that is what it currently does. but it does not make too much sense because for the same reason (ie median) trucks cannot cross lane to access building, they cannot cross lane to do anything else either. |
Who, me? I'm actually in favor of this. I just want to pick it apart and make sure we aren't risking false positives.
I don't even think you have to limit it to None lanes. but the elevation difference needs to fall within a range (even for None) to avoid false positives on lanes that are above the roadway and don't divide it. (see image below)
In any case, this isn't really very urgent for me, since I'm gonna have to account for crossing oncoming lanes regardless of the presence of a median. 🤷♂️ Lanes above roadway that don't divide the road: |
This and only this. There no other use of |
I'd hate to see th is abandoned. If we can get even a fraction of it working it will be huge improvement for creators and users alike.
Assuming that there are no vehicle lanes overlapping them to a sufficient degree. But yes, if we can get this it will be awesome. |
@kianzarrin I think we should hold off on implementing this until displaced lanes are done. The two features have a lot of overlap, since we're basically talking about grouping lanes for lane transition rules, and we don't want a repeat of the It might even turn out that combining the two features makes sense, but I won't know that until I get into it. |
I am closing this issue because I've formally defined an enhancement to achieve what it was after. #1528 |
I would like to see an optional setting which would alter the behavior of the Can Cross Lanes road asset flag as follows:
This is different from the standard behavior, in which vehicles simply cannot cross over the oncoming lanes to reach their destination, without going to an intersection.
This would allow the creation of roads with multiple medians, like Queens Blvd in NYC. Ramps connecting the express and local roadways could be configured using the lane connector, and rendered using the Intersection Marking Tool.
Screenshots?
Notes or questions?
Simply using the lane connector to restrict vehicles to the proper roadway wouldn't be any good, because emergency vehicles ignore it.
A possible alternative approach is to add a flag to the lane connector imposing its rule on emergency vehicles on a node-by-node basis. To really be usable, there would also need to be a shortcut similar to "Stay in lane" to easily set up lane connections that don't cross non-vehicle lanes.
Tagging #89 , #192 , #503 , #504 , #558 , #506 , #64 , #646
The text was updated successfully, but these errors were encountered: