question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Update signs, props, etc., to reflect road customisations

See original GitHub issue

See also: https://github.com/krzychu124/Cities-Skylines-Traffic-Manager-President-Edition/issues/124

Been pondering this for a while, I think the only way to achieve it would be mini “add-on mods” that tell TMPE, for a given road asset (or collection of assets), details about the road speed signs.


TMPE would come with a default list of vanilla speed signs; for any roads that aren’t part of a roadcollection, TMPE will try vanilla sign.

However, any roads using custom signage will have to provide the definition file that tells TMPE about the custom signs.

A template mod would be provided for asset authors (or users who use roads by other authors and want to get the signs working), and all they have to do is change some values and fill in an XML file then publish as mod to workshop.

As a rough mockup of the xml:

<tmpe xmlver="1">

  // name must be unique per author
  <roadcollection name="UKRoadsRevived" author="authorname">

    // adds this road to the group
    <asset id="workshopid.prefabname"> 
    ...
  </roadgroup>

  // where do signs come from for this group?
  <signsfor roadcollection="UKRoads">

    // note: could be in separate asset pack
    <speed value="30" assetname="workshopid.propname">
    ...
  </signsfor>
</tmpe>

So, if user changes road speed, TMPE can find out what road group it’s in (eg. “UKRoadsRevived”) and from there work out the ids of speed signs for each speed.

It knows current speed and driving direction, so it can find existing speed sign on the relevant side of the road. It can then place a new speed sign (with height, rotation, etc of old sign) and hide/delete the old sign.

If no old sign is found, TMPE won’t add a new sign. This prevents unwanted signs appearing.

The XML structure above should facilitate different types of signs at a later date. For example, we could add in toggling of Parking signs (or relevant roadside props) that can be toggled on and off when parking restrictions are applied.

Issue Analytics

  • State:open
  • Created 5 years ago
  • Comments:16 (10 by maintainers)

github_iconTop GitHub Comments

2reactions
tony56acommented, Jun 29, 2019

Hi,

Quick question, is the envisioned end-state for this task supposed to include the addition of new props on a road, or just the replacement of existing props?

0reactions
originalfoocommented, Jul 9, 2019

I guess bulk of grindy code is conversion of font to texture, so for UI that only needs doing once per choice of signage style.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Steam Workshop::Road: Signs, Props, Bollards, Infrastructure
This collection contains all type of road signs such as: speed limits, highway signs, direction signs, etc. Items (676). Subscribe to all.
Read more >
What am I doing wrong? After "beautifying" an area with ...
Another workaround is I build some landscaping into custom road assets, like green decals and trees on bike paths that I used to...
Read more >
Road Sign Prop
Check out our road sign prop selection for the very best in unique or custom, handmade pieces from our signs shops.
Read more >
Judazzz' C:SL Goodies - Update: American Roadsigns v2. ...
Mark-a-route implements the second method using custom sign props( although it also renders the sign prop itself ). One issue with that is...
Read more >
Prop updates updating state in hooks · Issue #14830
I am curious as to why this doesn't already happen automatically through useState and useReducer , and wondering if this is the correct...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found