Search Unity

EasyRoads3D v1.0 for Unity - Plugin version Online

Discussion in 'Assets and Asset Store' started by raoul, Apr 29, 2009.

  1. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    What kind of modifications are you referring at and which part is taking so long to complete? Because in your previous post you wondered if it is possible to exclude the terrain and the road objects. Did you try unmarking the terrain and roads as static?

    We have several computers here, on one "Auto" is always switched off regardless the scene contents. It slows down the editor workflow to the extend that it becomes unworkable. You do have a large scene so I guess processing can be a lengthy process.

    Thanks,
    Raoul
     
  2. CommunityUS

    CommunityUS

    Joined:
    Sep 2, 2011
    Posts:
    240
    I haven't purchased this yet, (pro version) but wanted to make sure I could swap the runtime road out with a runtime river easily in the example. Please let me know if this is a simple thing, once we chat I will be happy to pickup pro.

    What I am doing is creating 5 runtime procedural terrains and tiling them. I get away with a tiny resolution of 64 and a terrain size of 2000 and height of 270. Will this runtime script be able to work on these dynamically generated terrains so I can have a river running from one side of the map to the other...so it may span up to 10 terrain tiles before I run it into a static object etc.
     
  3. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735

    Hi productofself,

    Just to be sure, it is not that you want to swap an already exisiting road in your scene for a river, you simply want to create a river through the API, is that right?

    This can be done:
    Code (csharp):
    1.  
    2. ERRoadType roadType = roadNetwork.GetRoadTypeByName("River");
    3. ERRoad road = roadNetwork.CreateRoad("Road Test", roadType, markers);
    4.  
    You can assign side objects to road types and mark a road type as "Sode Object". This means that no road will be created. In the above example a new river will be created using road type "River" which has the required river bed and river surface side objects activated, the shape will be created according the passed marker array which are control points for the river shape.

    Is this all done at runtime in your game or in the Unity editor? It seems you have a large terrain, this will require optimization for especially the river surface. So if this is run time in your game you probably want to experiment in the editor to get the right resolution etc.

    Let me know if you have further questions.

    Thanks,
    Raoul

    v3: http://forum.unity3d.com/threads/easyroads3d-v3-the-upcoming-new-road-system.229327/ :)
     
  4. CommunityUS

    CommunityUS

    Joined:
    Sep 2, 2011
    Posts:
    240
    you simply want to create a river through the API, is that right?
    -Yes

    thanks for the fast reply, my detail resolution is low only 64, typical is 512ish as you would know better than me. it takes about second to generate a new terrain at runtime at that resolution on a mid grade pc. on a separate thread. do you use threading as well? fps stays above 30 during generation.

    i wasn't sure if you used this detail resolution variable as well, if so it should generate fast. however it may look blocky...like i can't place grass on my 64 res terrain as it crudely cuts off at the end of that. how would i create curves and stuff in the river through script at runtime? is this all in the example? it looks like you pass it markers? but earlier in thread i saw you mention no markers are used from unity editor if doing runtime.

    Here is some pics of the resolution settings and blocky grass. Do you think the river will be blocky at this detail res? or do you use another variable?



     
  5. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Looking at the terrain settings I am not sure if this will work well. Size 2000x2000, heightmap Resolution 65, heightmapscale of about 30(?). That will result in a blocky riverbed and visible river surface since it is impossible to add detail points. Have you tried manually digging a river bed in your terrains? And indeed removed grass patches will look blocky as well, like in the sceenshot, when using 64 for the detail resolution.

    Currently no threading is used but that can be implemented. That is the good part of these low level terrain settings, processing will be relatively fast anyway.

    Could you point me to where I wrote that and what you exactly mean with that. The shape is based on marker positions (control points) you pass. This is both at runtime as in the Unity editor.

    Thanks,
    Raoul
     
  6. CommunityUS

    CommunityUS

    Joined:
    Sep 2, 2011
    Posts:
    240
    ...the quote and page that kinda got me mixed up. control F that page for runtime and marker, and it gets a bit confusing. i haven't purchased the product so that adds to confusion, I wanted to make sure i could use it for the river purpose which would be the reason to buy.

    It sounds like there is some doubt, what if I boosted to 128 res instead of 64, any better chance? any possible chance of a screenshot at these settings so i can decide. It does sound like I could make it work with editor, but runtime doesn't give us enough controls? or is this a not yet situation?

    LOL...looks like these are 2 different threads, that's what using search does for ya, I will keep the topic here.
     
  7. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    That is referring to the API being scripting only, it does not provide a visual GUI at runtime like in the Unity editor Scene View window and Inspector.

    128 will result in an heightmapsscale of about 15 units on 2000x2000. The blockiness will cover about 50% of the river width when a width of 30 is used. Add a plane to your scene matching the river width you have in mind and a length of 5 times larger or so. To maximize the blockiness, position the plane diagonally on your terrain. Then create a river bed around the plane using the terrain shaping tools. That will give you an idea of the end result for your specific terrain setup. That is why I asked if you tried to create a river shape manually.

    Yes, this is the v1 thread, a very old thread, that is why I posted the v3 thread link in my initial reply. :)

    v3: http://forum.unity3d.com/threads/easyroads3d-v3-the-upcoming-new-road-system.229327/

    Thanks,
    Raoul
     
  8. CHEFerrol

    CHEFerrol

    Joined:
    Mar 31, 2016
    Posts:
    18
    Hi Raoul:
    I have created a road with only 5 side objects. Now I need to add a Simple Bridge into the road.

    I have configured the simple bridge into the Side Object Manager, I have activated the simple bridge into the kind of road I am using (Motorway 2x2), in the section Active Side Objects, I have presshed the boton Refresh Road Network (I am not sure if this was necesary). Previously, I had defined to Markers of the road like Bridge Segment.
    But the bridge segments do not appear. Could you help me?. I am using v.3

    Thank,s
    José L. de Nicolás
     
  9. raoul

    raoul

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

    Is this about the Simple Bridge side object in the beta package? In that case what do you mean with this:

    Did you change settings for this side object in the Side Object Manager? In the editor window you will see a "Build Test meshes" button. This will temporarily instantiate the side object in the scene so you can see whether it is build correctly using the current settings.

    "Refresh Road Network" is not required in this case, this is more intended to refresh the road network after for example a package update.

    Other than that it is hard for me to comment without further info.

    Or perhaps this is the reason:

    Do you mean "Bridge Segment" in the road Inspector options for that marker? All this does is deactivate terrain deformation for that marker. But this by itself will not build bridge geometry. This is done in your case by activating the Simple Bridge side object for the respective markers. Also note that when activating these side objects, conform the side object settings for Simple Bridge, "Bridge Segment" will be toggled on automatically so there is no need to manually activate "Bridge Segment".

    "Bridge Segment" can be used in case no bridge side objects are used but custom road shapes where the bridge is part of the road geometry. Like the highway overpasses in the main scene of the beta package.

    Thanks,
    Raoul
     
  10. CHEFerrol

    CHEFerrol

    Joined:
    Mar 31, 2016
    Posts:
    18
    Thank you Raoul:

    I wish build bridge over the river you can see in the picture.

    You can see that into the marker I have checked Bridge Segment box (I am using the motorway 2 lines and the motorway 2x2 has checked Bridge Simple like actives Side Objets) but into the marker it is no possible to select Bridge simple into the combo box.
    As you can see the Test Mesh runs correctly.

    Thank´s Raoul.

    José L. de Nicolás
     
  11. CHEFerrol

    CHEFerrol

    Joined:
    Mar 31, 2016
    Posts:
    18
    ... the picture is this. -)
     

    Attached Files:

  12. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Do you get error messages?

    Can you Deselect / Reselect the Bridge Side Object in the main Side Objects list of that road? Does it now appear in the markers dropdown?

    Can you create a temporary road and active the Simple Bridge Side Object? Does it appear in the markers dropdown?

    If you want you can email me a link to download this scene so I can look at it.

    Thanks,
    Raoul
     
  13. CHEFerrol

    CHEFerrol

    Joined:
    Mar 31, 2016
    Posts:
    18
    Hi Raoul:

    The higway it´s running perfectly.
    Very good tool!!!.

    Thank you.

    José L. de Nicolás
     
  14. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
  15. voncarp

    voncarp

    Joined:
    Jan 3, 2012
    Posts:
    187
    Is it possible to get the road broken up into many segments upon building instead of having one giant mesh?
     
  16. raoul

    raoul

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

    Since you are posting in an older thread, are you still using v2? In v2 you have the option to start a new LOD segment for every marker. This does what you are looking for, each segment will be a separate game object / mesh.

    This will also be possible in v3 but since v3 supports crossings and every road segment between crossings is a separate object, the road will already automatically be split in pieces when using crossings.

    Thanks,
    Raoul
     
  17. voncarp

    voncarp

    Joined:
    Jan 3, 2012
    Posts:
    187
    Hi Raoul,

    Thanks. I see how its done now.

    Version 2. Yes. This thread was linked from your description on the Asset Store.
     
    Last edited: Jul 13, 2016
  18. raoul

    raoul

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

    Ok, if you are on v2 that should work well :)

    Yes, I should make that more clear, the "Showcase" link goes to this page in the Unity Showcase forum (v1). The "Assetstore" link goes to the v2 thread in the Assets and Asset Store forum.

    And there is the v3 thread

    Thanks,
    Raoul
     
  19. boadleFTG

    boadleFTG

    Joined:
    Nov 23, 2017
    Posts:
    18
    Hi guys,

    Is it possible to create Dynamic Prefabs (eg 45 degree road intersections) and yet still retain the ability to adjust the sidewalks on them? Currently, it appears that I can either use Custom Prefabs 'out of the box', and be able to adjust the sidewalks, or create my own prefabs but without the sidewalks functionality? Or am I mistaken?

    Thanks!
     
  20. raoul

    raoul

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

    Angles on intersection corners are limited to 90 degrees in the v3.2 built-in dynamic connection system.

    In v3.2 45 degree corner angles can indeed be done using Custom Connection prefabs based on imported models. In that case the sidewalks must be part of the connection model. Roads connected to these custom connections can still connect to dynamic X and T connections with the same built-in sidewalk shape active.

    V3.3, available in betas, has a new built-in connection type, the Flex Connector. This does support flexible angles. The current beta also includes a first preview with support for built-in sidewalks.

    Thanks,
    Raoul

    Btw. this is the old v1 thread, https://forum.unity.com/threads/easyroads3d-v3-the-upcoming-new-road-system.229327/ this is the current v3 thread


    .