Search Unity

[1.11.4][Standard RP/LWRP] Free Opensource Road Creator

Discussion in 'Assets and Asset Store' started by MCrafterzz, Feb 15, 2019.

  1. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    Yes I'm still updating this!

    1.10.1
    - You can now divide roads with D plus left click on a point (not control point, or first/last points). Comes with undo support
    - Exposed traffic lights' time since last transition so that you have more control (so now they are accually usual as different traffic lights can be in different parts of the red perioud)

    - Fixed being able to remove points from the first road segment when being connected to an intersection
    - Fixed only selected road automatically retrieving lane markings when creating an intersection
    - Fixed traffic lights not being movable
    - Fixed prefabs being placed in the wrong location when bend objects is false and gaps are large
    - Fixed roundabout uv issues
     
    Last edited: Aug 18, 2019
  2. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    Always nice with some bug fixes!



    1.10.2
    - Added Texture Scale option to intersections/roundabouts
    - Roundabout now generate the center ring texture all around
    - Improved default connection position when connecting roads to existing intersections
    - Fixed Street lamp post prefab having the player tag
     
    Last edited: Sep 13, 2019
  3. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    Time for some new features!


    1.11.0
    - Added intersection main roads
    - Added option to rotate the road (change the y offset of: start/end left/right)
    - Added 1 lane roundabout
    - Added 4 lane road with double lines

    - Fixed automatic intersection curve placement sometimes being way off
    - Fixed intersection extra meshes texture stretching depending on intersection size instead of repeating
    - Fixed road texture not always updating when moving a point with the move handles
    - Fixed new roads segments having a reference to the last segment's bridge settings instead of a copy
    - Fixed not all road textures having transparent background
    - Fixed street lamp post prefab not having a collider
     
    Last edited: Sep 25, 2019
  4. suchoparek

    suchoparek

    Joined:
    Nov 10, 2014
    Posts:
    11
    Hi MCrafterzz, great job with this! I was using Road Architect, but it was old and limited, luckily I've found your asset. :)

    For my project, I need to move a bunch of car along the road. I've tried the classic quadratic bezier interpolation using the point of the segments, but the resulted path is slightly offset in y when the terrain goes uphill or downhill.
    I guess you adjust the mesh to stick it to the terrain. Is there a function I can use to get the real road curve?
     
  5. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    It adapts to the terrain depending on which options you use for the segment you can change it to ignore and in that case you can use the Calculatepoints method in the roadcreator class.

    If you want to use the terrain adapt mode then I believe the best way to get the points is to loop through the segment's vertices adding 2 at a time and getting the center between the current and next vertex (0 and 1, 2 and 3, 4 and 5 etc). It would take some performance but if you do it once and then cache that information then it shouldn't be a performance problem. Let me know how it goes and don't hesitate to ask more questions! Also btw thanks for using my tool! :D

    Edit: another important thing is that it uses cubic better curves (three points) and not quadratic better curves (four points)
     
  6. suchoparek

    suchoparek

    Joined:
    Nov 10, 2014
    Posts:
    11
    Thank you for the quick response. :)
    I've managed to use CalculatePoints to get the position at t with interpolation and the rotation with the derivative. It works well.
    About intersections, for every path I've created a quadratic curve with the center of the intersection as control point. When the car enter the intersection, the rotation is not smooth, but I think I could manage it by using the tangent point or something.
    For performance sake, I've stored the points of every road and all the possibile intersections paths, the only script occuring in runtime is Dijkstra algorithm to calculate the path, that is really quick with so few nodes to take in account (one per segment plus the intersections once).
    Now I have another question: is there a way to create an intersection at the middle of a road, maybe by split the segments? It would be useful. :)
     
  7. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    Yes I've got you covered, you can use CTRL + D while clicking on a non-control point on the road to split it into two roads at that position. Psst check out https://github.com/MCrafterzz/roadcreator/wiki/Instructions! It shows you all controls and shortcuts. Glad you worked it out!
     
  8. AMINELABS

    AMINELABS

    Joined:
    Jun 7, 2018
    Posts:
    7
    Hi, when i create a road in the last point of a segment the road is deformed like this
    http://prntscr.com/pa5rxz
    Can you help me ?
     
  9. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    The surface is probably a bit uneven and the road tries to adopt to it. In this case I recommend changing the terrain adapation mode for all segments from adapt to ignore.
     
  10. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    I'm delighted to see that this tool is starting to gain momentum and catching people's eyes. I am constantly updating this tool and today it's time for another update.


    1.11.1
    - Intersection extra meshes are now smarter and try to prevent overlapping themselves on tight corners
    - Fixed intersection connection point occasionally not being removed causing issues when playing the game
    - Prefabs with other layers than default now keep their layer in prefab lines

    Oops there were a few irritating bugs in the previous version that have now been fixed:

    1.11.2
    - Fixed intersection main roads not being visable when intersection y offset is more than 0.02
    - Fixed error when using the tool with Standard Render Pipeline materials

    1.11.3
    - Fixed intersections not working correctly when using both extra meshes and main roads
    - Removed the right line of the 2L 1 side main road material
     
    Last edited: Oct 12, 2019
    GCatz likes this.
  11. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    Will using this tool myself to develop the Drive Quest game I found a few bugs that had to be fixed!

    1.11.4
    - Fixed center roundabout meshes not generating when width was zero and yoffset was negative
    - Fixed intersection extra mesh tiling being way to high on sharp turns

    [DOWNLOAD]
     
  12. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    Ok so a small update on this. There are some issues with this and I would like to change some of the base systems, so therefore I'm going to start working on 2.0 that unfortunenly will not be compatible with 1.x but will hopefully be quicker to use as well as more powerful.
     
    GCatz and Prodigga like this.
  13. Mad_Mark

    Mad_Mark

    Joined:
    Oct 30, 2014
    Posts:
    484
    @MCrafterzz Have there been any updates?
    Is 2.0 currently available?
     
  14. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    I've spent a lot hours on it (3 months) recreating it entirely from scrath with inproved usuability and flexibility in mind. Currently the only thing left is terrain deformation, then I'll release it. Unfortunely I will charge for it as I've spent so much time on it and there's assets I want to buy, so I have to earn some money myself to buy those. I will upload it for cheaper than most alternatives to make it possible for more people to buy it. It will probably be done in 1-2 weeks. I hope you guys don't feel let down.

    EDIT: I have finally uploaded it, give it a try!: https://forum.unity.com/threads/1-0-0-road-creator-pro.826050/
     
    Last edited: Feb 11, 2020
    HeadClot88 and Prodigga like this.
  15. baturalpkabadayi

    baturalpkabadayi

    Joined:
    Jan 19, 2022
    Posts:
    2
    I cannot use the tool shift left click won't work. Anyone has any clues?
     
  16. MCrafterzz

    MCrafterzz

    Joined:
    Jun 3, 2017
    Posts:
    354
    Make sure you have gizmos enabled
     
  17. baturalpkabadayi

    baturalpkabadayi

    Joined:
    Jan 19, 2022
    Posts:
    2
    Hello MCrafterzz, few questions over here:
    Is there a way to adapt the already created road network on a different terrain?
    And is there a way to change the settings/values for all created road segments?