Search Unity

World Building EasyRoads3D v3 - the upcoming new road system

Discussion in 'Tools In Progress' started by raoul, Feb 19, 2014.

  1. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
  2. AlbertoMastretta

    AlbertoMastretta

    Joined:
    Jan 1, 2015
    Posts:
    71
    Hey Raoul!

    First of all, I want to thank you again for this great tool, I use it very often and I'm so glad it exists.

    I wanted to notify you on a couple of bugs that I'd like to get fixed. The first one is that on shape objects, the end object is being placed incorrectly, and overlaps the ending of the main shape object. It is not being correctly placed just on the edge of the main shape. I've checked my meshes pivots and prefabs thoroughly and believe its not a problem I created. I'd love to see this fixed.

    The other Problem I have, is that sometimes I make the mistake of trying to place a circular point right after another circular point. That causes the tool to freak out and generate a mesh insanely large, and ends up crashing unity. Its something that we as users can prevent by not doing it, but I believe it would make the experience a lot nicer if the tool didn't allow us to place a circular point after another circular point. Just to prevent that problem from ever happening.

    That's all for now, thanks again for keeping improving this tool with the constant updates and ultra fast replies, you rock.

    Cheers!
     
  3. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hi Alberto,

    Thank you, glad to hear you like!

    I will check the End Object placement for Shape type of side objects. Is this purely a positioning issue or is this related to the other controls such as the alignment? Does this always happen?

    The circular controller type can indeed have unexpected results depending on the marker positions and, as you wrote, controller types on other markers. Optimizing this is on the To Do list. We usually simply do a Undo when this happens. Unity crashing should obviously not happen, we never experienced that. I will move this up on the To Do list.

    Thanks,
    Raoul
     
  4. Artomiano

    Artomiano

    Joined:
    Dec 1, 2014
    Posts:
    200
    Hi raoul,

    do you already have a guess when ER3 will be final? Is there a tendency? It seems like a neverending story... :rolleyes:
     
  5. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hi tom-art,

    ER v3 will be final once v4 is released :)

    What exactly are you waiting for? Are you experiencing issues?

    New betas are released at least every month, the latest betas are stable for production. Getting the final v3.0 released indeed may seem to be a neverending story but that merely is because new features are being added all the time and I want to release it together with additional resources, a new demo project, more assets, new tutorials. That is what is being worked on right now, in terms of development time it is almost a package by itself because of all the features that need to be covered.

    Once v3 is released, v3.1 will follow, v3.2, so new features will be added as well after v3.0 is released. I wouldn't hold back right now because it is still in beta. v3 is included in the current asset store Pro license, no need to upgrade once it is officially released, but the price will go up again once it is released.

    Thanks,
    Raoul
     
    Last edited: Nov 18, 2016
    antoripa likes this.
  6. Artomiano

    Artomiano

    Joined:
    Dec 1, 2014
    Posts:
    200
    Hi raoul,

    I check your thread every week, so I'm aware of the fluid development. And I will not talk about the costs. Your cost level is very fair, in my opinion! That you give us many updates and new features is great. Yes, you made a great job! ;)

    My thoughts are about safety and stabilty. In most cases, you have to say "it's a beta - do not use it for production". So, why don't you offer a final version? Make a feature cut for v3.0. And later you can - and should - put v3.1, 3.2 and so on at the asset store - as regular updates. Why don't you? I think the actual version has got enough features.

    I think, it would give us devs more development safety, to know to have a "final" version at work that is supported further way. Do you know what I mean?

    P.S. I bought ER already. :rolleyes:
     
    Last edited: Nov 18, 2016
  7. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Yes, I understand, that is why I emphasized that the beta is stable for production. That is our own experience but also based on bug reports and several users (who have been working with it from an early stage) already mentioning months ago that it is stable for release.

    At the moment only small improvements/features are added that I think are useful. More time consuming features are planned for v3.x.

    Personally I just don't think it is right to release the package as it is now, if you look at the review section people do mention the lack of tutorials, outdated tutorials (although it is not entirely clear if they are referring to the v2 tutorials or the provisional v3 videos).

    So that is more the reason why v3 is still in beta rather then that it is not stable yet. I like to release it including a new demo project with clear examples of all the features and additional tutorials. Meanwhile (in general) there is the incentive of the lower asset store price to get it now and start working with. :)

    If something is not clear, please ask here or email me and if people are experiencing bugs, please report them.

    Thanks,
    Raoul
     
    Last edited: Nov 18, 2016
    antoripa likes this.
  8. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Hi,
    I have 2 distinct roads. Can I merge ? How ?
    upload_2016-11-22_10-45-15.png
     
    Last edited: Nov 22, 2016
  9. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hi antoripa,

    If the two roads are of the same road type, you can select both markers using SHIFT + Click, afterwards Shift + J, or "Join Selected Roads" in the Inspector will merge the two roads.

    If the roads are not of the same type you will need a connection piece in between the two. But if the only difference is the material you could also first create the two roads as one road, then change the controller type for the markers surrounding this marker to Straight XYZ. You can now split the road road at the middle marker and assign another material or road type (with the other material) to one of the two selected roads.

    Thanks,
    Raoul
     
  10. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Hi @raoul
    I bought your asset today ... v3 is really nice ...is there any tutorial about bridges ? I saw oustaindg picture on your web site... and is the beta on assest store the latest ? I downloaded today morning.
     
  11. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Glad to hear you like it :)

    Currently there are no tutorials specifically about bridges. You can find all provisional videos at the top of the Quick Start section in the manual. New tutotials will be available once v3.0 is final and released.

    But the beta package includes examples of different types of bridges, done by using side objects and custom connection prefabs.

    When making bridges using side objects you have to set the specific markers to "Bridge Object" to avoid terrain deformation on these sections. This is done automatically when you mark a side object as "Bridge Object".

    For bridges that should follow the road shape you want to use the Procedural Mesh Object side object type, the "Simple Bridge" example in the package. This works like any other procedural side object type. For bridges that always look the same you can use the Mesh Object side object type, the "Motorway_2L_Bridge1" example in the package. This type of bridge is explained in the manual. You can see examples of both bridges in "Scene Main".

    "Scene Main" also includes examples of bridges done through custom road shapes / connection prefabs, the highway overpasses. This is based on your own meshes turned into Custom Connection Prefabs, there are several videos showing this process, the customized Road Network videos. When you pull out new "roads" from these connections the roads will inherit the shape of the connection. That way the bridges are instantly created without using side objects.

    Which option to choose depends on the type of bridge you need.

    Let me know if you have further questions.

    Thanks,
    Raoul
     
  12. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Thanks a lot for your prompt reply ... I will do few test in the next way ....
    I am going to test even procedural creation ( I mean in real time ) with some algoritm I created to create smooth path on mountain .. any suggestion from your side about how use API ? Are API full avaliable ?
     
  13. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    I would definitely recommend to go through the first sections of the manual and check how everything works before starting to build your scenes, also regarding side objects, what options you have. It will help getting the most out of the tool.

    All the main functionality, creating roads etc. is included in the scripting API. Eventually all the editor functionality will be available in the API. At the moment it is being epanded upon user requests as releasing v3.0 has priority.

    The beta package includes an example ("runtime scene") on how to create a road at runtime and have an object follow it afterwards. Apart from that is documented in the manual.

    Thanks,
    Raoul
     
    antoripa likes this.
  14. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    I will follow your suggestions. Thanks a lot and have a great day ( or evening ) ...cheers,
    Antonio
     
    raoul likes this.
  15. Der_Kevin

    Der_Kevin

    Joined:
    Jan 2, 2013
    Posts:
    517
    Hey! runtime Geneneration works great!
    easyroad_gen_3.gif

    just two more questions ;)
    1) can i somehow erase all trees and the grass (unity terrain) that is under the road?
    easyroad_gen6.gif

    2) can i also add side objects an fences to the road that is generated at runtime?

    Cheers!
    Kev
     
    antoripa likes this.
  16. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Hey .. it looks like we are working on the same stuff ...
     
  17. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hi Kev,

    Good to see you got the runtime API working :)

    Yes, you can do that:

    ERRoadNetwork.BuildRoadNetwork(bool splatmaps, bool trees, bool detail)

    Using this you can optionally embed the road shape in the terrain splatmap, remove trees and detail objects. Please make sure to back your terrains when using this inside the Editor. Terrains should restore well but just for extra safety... We always simply duplicate the terrain in the project panel.

    Full side object control per marker is not yet added to the API but you can assign side objects to road types in General Settings > Road Types. These Side objects will also be build when generating the road at runtime. You can also create side object type of "road types" (no actual road). That way you can create separate fences, walls, etc.

    Thanks,
    Raoul
     
    Der_Kevin likes this.
  18. Himanshuchahar

    Himanshuchahar

    Joined:
    Apr 15, 2016
    Posts:
    42
    Hi Raoul,

    I want to create a simple road on mountain terrain. But it came out like this:

    upload_2016-11-25_11-48-8.png

    Can you please tell me how to fix the above bump using easyroads3d v3?
    Just to add, I am using Gaia tool to create terrain.
     
  19. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Hi,
    i have created that road using runtime API .. I am trying to follow terrain shape as it's has been created with real data 8192 height map resolution. In few points that the effect I am getting ...any suggestion ?
    Btw .. even if I do in standard manual approach there are those points.
    Grab 20161125082232 w1900h1200 x5278y1421z-6420r258.jpg
     
  20. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hi Himanshuchahar,

    Looking at that screenshot there is no terrain deformation at all.

    Is this screenshot taken in Edit Mode or in Build Mode?

    If it is Build Mode, could you check the Terrain Deformation checkbox in the Inspector in Edit Mode after selecting the road?

    Thanks,
    Raoul
     
  21. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735

    Hi Antoripa,

    The heightmaop resolution by itself doesn't tell evrything although 8192 is very high. The heightmapscale is important (size vs heightmap resolution), what is your terrain size?

    Is that really terrain popping through the road or z-fighting? Which shaders are on the road material and what is the Raise level of the road network in Build Mode?

    Can you show the road in Edit Mode? It looks quite bumpy (something that is coming up in the next release), what are the marker positions and what is the road resolution?

    Thanks,
    Raoul
     
  22. Himanshuchahar

    Himanshuchahar

    Joined:
    Apr 15, 2016
    Posts:
    42
    Tried that, but no luck :(
     
  23. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hi Himanshuchahar,

    Can you make sure that "Hide White Surfaces" in General Settings > Scene Settings is NOT toggled on and show a screenshot in Edit Mode, with both the Scene View window and the Inspector visible?

    Thanks,
    Raoul
     
  24. Himanshuchahar

    Himanshuchahar

    Joined:
    Apr 15, 2016
    Posts:
    42
    Hi Raoul,

    upload_2016-11-25_15-32-3.png
     
  25. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    That looks alright.

    You mentioned Gaia, some terrain tools have the option to lock the terrain heightmap. Could it be that is interfering with the EasyRoads3D heightmap modifications?

    Otherwise the only remaining possibly reason why the terrain is not adjusted is that your scene has multiple terrain objects and you have chosen to update only the selected terrain in the Build Mode terrain dropdown and that terrain is not the terrain in the screenshot.

    Thanks,
    Raoul
     
  26. Himanshuchahar

    Himanshuchahar

    Joined:
    Apr 15, 2016
    Posts:
    42
    I have only one terrain, let me quickly check with Gaia settings. How can I delete the particular marker?
    And in v2 I was able to see the marker list, in v3 I am not able to see the list, where can I see it?
     
  27. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Ok, let me know if this is not Gaia related. In that case, the first thing I would try is do a simple text in a new scene with a manually created terrain.

    Shift + R removes the selected marker(s), Shortcuts & Scene Operations. In v2 markers were separate game objects, that is no longer the case in v3. Is there a specific reason why you want to see the markers in a list?

    Thanks,
    Raoul
     
  28. Himanshuchahar

    Himanshuchahar

    Joined:
    Apr 15, 2016
    Posts:
    42
    Ok Sure. Thanks
    No specific reason, just wanted to know :)
     
  29. Der_Kevin

    Der_Kevin

    Joined:
    Jan 2, 2013
    Posts:
    517
    really, well maybe we should put our findings together when we are done :)
    so about the terrain that slipping threw the roads on your screenshot - i have the same issue. solved it by raising the road to 0.2 on the Y axis after its generated. for me thats alright cause iam making a top down game, for a third person game the floating road might look weird

    one more question for @raul:
    is it possible to connect 2 roads to each other? so that they are seamless? at the moment i have a small gap between the roads and even if i would manage to close this gap, the road would overlap with each other which wont look that nice an flicker a little bit. also texture wise.
    (for runtime generation)
     
    antoripa likes this.
  30. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Sure .. I agree .... and thanks for the suggestion ... I will send you a PM with more details about what I am doing ..
     
  31. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hi Kev,

    0.2 is a lot and will visible with cam angles relatively close to the road. Up to 0.05 will be fine unless the cam is really close to the road. But for terrain areas as flat as in antoripa's screenshot 0.02 should be enough even when using the Unity standard shader without an offset.

    That option (Shift + J in Scene View after selecting the two markers that should connect) is not yet added to the scripting API. I will add that. But this will only work for road objects that share the same road type otherwise a connection prefab is required between the two roads.

    Thanks,
    Raoul
     
  32. Der_Kevin

    Der_Kevin

    Joined:
    Jan 2, 2013
    Posts:
    517
    ah, great - just out of interest: any ETA for that?
    sure, only if its the same type.

    true, maybe i works because iam zoomed out pretty far.
    btw, here is a video which shows the runtime API in action:


    the terrain gets generated on startup, two random start and end points get set on the terrain, A* finds a path, EasyRoad paints a Road along that path - Easy ;)
     
    local306 and raoul like this.
  33. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hi Kev,

    Great work! Must be a challenge also staying away from those mesh rocks. :)

    I can see why you need to raise the road a little bit further. Even when building your roads manually in Scene View you have to be careful placing markers in hilly areas let alone generating your roads from code.

    To get the best results on a specific terrain heightmapscale you can experiment with bends and height differences and changes in slope angles in general. Find the limits of what the terrains heightmapscale can handle and optimize your runtime script for that.

    A new update is about ready and will be available next week, adding the "connecting two roads" option shouldn't be too much work so it will probably be available in that release.

    Thanks,
    Raoul
     
    antoripa and Der_Kevin like this.
  34. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    That's really nice .....
    You wrote that is with MapMagic .. I am wondering if is full random .. I mean even road creation ....So far with MapMagic I created a generator for small villages .. and I am more focus on that than road....

    I am using runt time road creation with static but huge terrain ( 16Km X 16 Km ) create streaming real world data in run time .. that's the reason I use RoadMap API with A* Path with cost to create the path ...
     
  35. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Hi @raoul ,
    now it works ...it looks pretty nice ...I changed terrain settings and introduced a cost function in pathfinding to create the points to create the roads ...I am vewry happy about your asset .. I look forward hearing about new features giving more "horses power" to API ....thanks a lot ...
    Btw .. is there any plan to use an image like a mask to create roads ....


    upload_2016-11-25_23-7-34.png
     
  36. Richard-_K

    Richard-_K

    Joined:
    Sep 27, 2015
    Posts:
    17
    Hi All,
    Just bought EasyRoad and am very happy with it. I am using v3 b8.2 and have lost the names for the road types and side object type. For example the following images shows the list of road types as a list of numbers rather than names. Is this something I cn fix or is it perhaps a bug?

    Many thanks,
    Richard.

     
  37. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Hi Richard,
    from my experience that's Unity serialitation issue. Yout check your serialitazion setting in Unity
     
  38. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Hi @raoul
    using the API is there any Event like OnPostBuildRoadNetwork ...
    If not .. have you any plan to add it ? Ideally I could create a wrapper class .. but not sure if I will have full controll and stabillity ...
     
  39. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735

    Hi Richard,

    Antoripa is probably right. Are you using Text Mode for Asset Serialization instead of the default Mixed Mode? In that case, this issue is covered on the troubleshooting page in the docs.

    In short, import the package in a new project using the default Mixed Mode for asset serialization, switch to text Mode afterwards, export the package and import this package in your working project using Text Mode.

    Thanks,
    Raoul
     
  40. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hi antoripa,

    Glad to hear you are getting good results now.

    What sort of images do you mean? Vector images like svg files? That is on the list for a long time but it is not asked for very often.

    Thanks,
    Raoul
     
  41. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    That would probably be useful, I will put that on the list to look into.

    Thanks,
    Raoul
     
    antoripa likes this.
  42. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Ok .. thanks
     
  43. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    @raoul Can I create Waypoints by API setting parameters like from the Inspectors ? That's would be great as I need those for my AI engine ...
     
  44. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Ideally I could use the markers .. but I am not sure if wp's are created diffrently from the overall track
     
  45. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    @raoul I am experiencing issue changing the road type from API.
    Whatever I create, I cannot change the material .. i am using that . .. road is created but always same material ( the one from default )
    ERRoadType roadType = new ERRoadType()
    roadType.roadWidth = 6;
    roadType.roadMaterial = Resources.Load("Materials/roads/single lane sides") as Material;
    roadType.terrainDeformation = true;

    I would even ask if I could load from API the road type and call by name ( i have seen the method but I do not koww how load a chunk of road preset from API ) ...I have workaroudn, but if there is always a feature I wouldn't re-invent the wheel.Thanks
     
  46. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hi Antoripa,

    You have access to the spline info throught he API.

    ERRoad.GetSplinePointsCenter()

    You can check the manual for futher options (left / right side of the road info)

    I will check updating the material assigned to the road type through the API. But the code you posted, does that run before creating the road or afterwards? If it is afterwards then indeed that will not work, you can do this to change the material

    ERRoad.SetMaterial(Material mat)

    Thanks,
    Raoul
     
  47. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    It runs before..
     
  48. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Yes, assigning a road material to a new road type through the API indeed doesn't seem to work well currently. It is fixed for the next update.

    Thank you for reporting this!

    Raoul
     
    antoripa likes this.
  49. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    Any ETA ?
    Is there any workaround in the meanwhile ? Right now I need just one kind of road in my scene .. and show the default material in a Middleage enviroment is not nice for my customer ..even I am just in prototyping and proponing options ...
     
  50. antoripa

    antoripa

    Joined:
    Oct 19, 2015
    Posts:
    1,163
    I improved the procedural road creation .. if you want to connect 2 points , like in the picture, it generate the smooth path , pass that to EasyRoad3D that create the road ... I can even have more points .. ( for exampel I wanna connect 5 cities scattered on my landscape ) but need to work on connection creating smooth one ...
    EasyRoad3d v3 Beta is a great tool really robust and flexible ..

    uno.jpg due.jpg
     
    raoul likes this.