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

    Hi Peter,

    That UV layout is supported for roads and crossings, I am not sure if it is for the Shape type of side object which is what you want to use for rivers. I will check this and add it if you cannot already do that. :)

    But should that indeed be calculated relative to the terrain position? What if you have a river crossing multiple terrains? The post on the aqua forum thread doesn't seem to make a reference to the position on the terrain. I guess it should simply take the bounds of the generated river mesh and calculate the UVs relative to these bounds between 0..1

    Thanks,
    Raoul
     
    Last edited: Jul 25, 2016
    dogmachris likes this.
  2. camel82106

    camel82106

    Joined:
    Jul 2, 2013
    Posts:
    304
    Out of the box AQUAS is taking a reference to one terrain. (flow texture has shape of that terrain and "size") So if you want to support multi-terrain water. You need to specify size of square by yourself. But it's still simple square. (he is taking only size of terrain from that referenced terrain and creating square plane. Maybe just ability to specify center point and width would cover all cases?

    And thanks for looking at it!
     
    dogmachris likes this.
  3. LaverZZY

    LaverZZY

    Joined:
    Aug 11, 2014
    Posts:
    12
    Hi Raoul,
    Can I split side object mesh to small meshs for culling? My road is 10km, the combined guardrail mesh is too large.:)
     

    Attached Files:

  4. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Ok, if AQUAS is taking a reference to one terrain, I will add a Terrain slot for all this and auto assign the terrain in the scene (if only one terrain exists).

    Thanks,
    Raoul
     
    camel82106 likes this.
  5. raoul

    raoul

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

    Especially for longer roads you indeed want to be careful generating side objects along the full road.

    Right now side objects should be split in separate objects once the unity max limit of 65.000 vertices is reached. Is that what you are referring at?

    More ways to deal with this will be added, like split by distance, marker, etc. You can also export the specific side object to .obj and optimize it in your modelling tool. Select the road object, click the arrow next to the specific active side object in the Inspector. Near the bottom you should see an export button for that side object only.

    Thanks,
    Raoul
     
    Last edited: Jul 26, 2016
  6. LaverZZY

    LaverZZY

    Joined:
    Aug 11, 2014
    Posts:
    12
    Thank you;)
     
  7. camel82106

    camel82106

    Joined:
    Jul 2, 2013
    Posts:
    304
    Hi,
    I was trying to assign RTP water shader flow map to road meshes in sample scene of Easyroads.

    If I assign RTP material to crossroad it's working.
    Not sure why, if I assign normal material with simple texture to straight road (bottom of screenshot). It's working as desired.
    But if I assign there RTP material it's black.


    Don't you know at first sight what is difference between straight road and crossroad regarding this.
    Thanks
    Peter
     
  8. DivergenceOnline

    DivergenceOnline

    Joined:
    Apr 19, 2015
    Posts:
    244
    For something calling itself "easy roads" this is super mega complicated dude. The videos are five years old, the manual just describes what this checkbox or that checkbox does and as far as i can tell there isn't a single tutorial available. Is that right, or does someone somewhere actually show you how to use it?
     
  9. raoul

    raoul

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

    With normal material, do you mean a standard diffuse shader or a shader with normal maps?

    I am asking thsis because in Unity 5 the mesh requires tangent info when using normalmaps. If no tangent info is available the object will be rendered in black like in your screenshot.

    Can you check in the Build Settings whether "Calculate Tangents" is toggled on, and optionally also General Settings > Scene Settings > Calculate Tangents in Edit Mode.

    Thanks,
    Raoul
     
    Last edited: Jul 27, 2016
  10. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hello DivergenceOnline,

    Are you using v2 or v3?

    The v2 videos are old but they are accurate. What do you find difficult to understand (if you are indeed using v2)?

    The first Quick Start section in the manual explains how to create roads.

    V3, this thread, is certainly more comprehensive then v2, provisional beta videos can be found here:

    http://www.unityterraintools.com/EasyRoads3D/v3/html/quick_start.html

    The manual also explains the workflow. Please let me know if you are still having difficulties with something specific.

    Thanks,
    Raoul
     
  11. JacobFalling

    JacobFalling

    Joined:
    Apr 27, 2014
    Posts:
    22
    Any hints on how to get started making a river with v3?

    upload_2016-7-26_20-59-23.png
     
  12. LaverZZY

    LaverZZY

    Joined:
    Aug 11, 2014
    Posts:
    12
    Hi Raoul,
    When i update to 7.7.3, the "Side object status" can not be click to show my side objects, Help me please!:)
     
  13. LaverZZY

    LaverZZY

    Joined:
    Aug 11, 2014
    Posts:
    12
    My unity3d version is 5.3.6f1
     
  14. camel82106

    camel82106

    Joined:
    Jul 2, 2013
    Posts:
    304
    Yes you are right when I add normal map on standard material it becomes black on road.

    I have tried to enable tangent info in build settings before (for easyroads) Even lightmap UVs and it hasn't helped. I'm not sure what you mean with scene settings - calculate tangents I cannot find it. I know that you can enable tangents calculation on model import settings. But I suppose that you are generating meshes for roads.

    Thanks
    Peter
     
  15. raoul

    raoul

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

    Is the river in your screenshot Edit Mode or Build Mode?

    The main demo scene includes an example of how you can create rivers with v3.

    Are the river surface and riverbed shapes in your screenshot the same side objects as used in the demo scene?

    Otherwise you can use that river as an example, especially the shape node settings for the riverbed snapping to the terrain on the outer sides and toggling on "Deformation Object" in the main Side Object Manager settings is important. "Target Object" for the river surface is also useful. You can drop your water prefab in this slot, the final river object will use the scripts and materials on that prefab.

    Thanks,
    Raoul
     
    Last edited: Jul 27, 2016
  16. raoul

    raoul

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

    General Settings (3rd tab from the right) > Scene Settings > Calculate Tangents in Edit Mode

    Roads being rendered in black comes up regularly in this thread, it is also covered in the Troubleshooting settings of the manual. The only known situation is when Tangent info is missing. Other then that all Unity Mesh data is applied to the mesh when building the roads.

    Can you try a Standard Unity shader with normalmap or the EasyRoads3D shader with normalmaps. If that works fine than indeed the black road in your screenshot is related to something else. I am not 100% familiar with the RTP shader. What exactly does it do? Perhaps it expects more info like vertex color info?

    Thanks,
    Raoul
     
  17. raoul

    raoul

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

    Yes, that is a 7.7.3 bug. The foldout arrow doesn't respond.

    Undo/Redo has meanwhile be implemented for this part of the Inspector and similar Scene View operations which resolves this issue. I can prepare a 8.0 alpha build if you want so you can test this.

    Otherwise, for now this can be triggered for example this way:

    Code (csharp):
    1.  
    2. using UnityEngine;
    3. using UnityEditor;
    4. using System.Collections;
    5. using System.Collections.Generic;
    6. using EasyRoads3Dv3;
    7.  
    8. public class APITestsEditor : ScriptableObject {
    9.  
    10. [MenuItem( "GameObject/3D Object/EasyRoads3Dv3/Display Road Side Objects" )]
    11. public static void  DisplayRoadSideObjects ()
    12. {
    13. ERModularBase scr = FindObjectOfType(typeof(ERModularBase)) as ERModularBase;
    14. if(scr != null){
    15. scr.showRoadSideObjects = true;
    16. }
    17. }
    18. }
    19.  
    Put this code in a C# script and place it in /Assets/EasyRoads3D/Editor. It will add the "Display Road Side Objects" option to:

    Top Menu: GameObject > 3D Object > EasyRoads3D > Display Road Side Objects

    Thanks,
    Raoul
     
    Last edited: Jul 27, 2016
  18. camel82106

    camel82106

    Joined:
    Jul 2, 2013
    Posts:
    304
    Sorry about troubleshooting settings in manual. I hate when people don't read manuals. You can be pretty sure that I have read it, but you know I didn't try to find this issue right now in it...

    My misunderstanding was that I was trying to find that tangent calculation in Unity settings. So both settings are inside of EasyRoads.

    Now it's working as desired. Only source of confusion was that if you enable tangent calculation in Build settings. And you have not enabled tangents calculation in editor. Than you will get black material on built road.

    Just for curiosity here is result of RTP shader used on road mesh. I want to use it for smaller water streams. For rivers it looks like AQUAS river solution is way to go.


    So with this and runtime API I'm able to generate water streams for whole map from script.
    Pretty incredible.
    Thanks!
     
    raoul likes this.
  19. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    No worries :), first you must know what you are looking then you must know where to find it...

    Yes, like mentioned in my reply further above to JacobFalling's questions, you can simply assign the AQUAS prefab to the "Target Object" slot of the river surface side object (provided that it uses a single river mesh only per object) and start creating your rivers.

    Thanks,
    Raoul
     
    Last edited: Jul 27, 2016
  20. LaverZZY

    LaverZZY

    Joined:
    Aug 11, 2014
    Posts:
    12
    solved. thank you!
     
    raoul likes this.
  21. JacobFalling

    JacobFalling

    Joined:
    Apr 27, 2014
    Posts:
    22
    Raoul,

    Thanks! I'm making progress, and the sample scene is helpful. A couple of questions:

    Where are "shape node settings for the riverbed snapping to the terrain on the outer sides?"

    How to I adjust the width and depth of the river bed? Is this done in the shape editor window?

    Fun tool!

    -Jacob
     
  22. raoul

    raoul

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

    You can actívate "Snap to Terrain" for each node in the Shape Editor Window.

    Yes, the shape of the riverbed can also be changed in the Shape Editor Window.

    And the node positions can be modified per marker, this way you can add variation to the width. The B Key actívates/deactivates white sphere handle display at the node positions for the selected marker in Scene View. You may have to zoom in a little bit if you cannot see these White sphere handles.

    Holding Shift while moving the handle will affect all node positions on the outer side, this way you can quickly change the river shape per marker.

    Newly added markers will inherit the shape of the previous marker.

    Glad to hear you like it! :)

    Thanks,
    Raoul
     
  23. Marco-Sperling

    Marco-Sperling

    Joined:
    Mar 5, 2012
    Posts:
    620
    Hi raoul,

    is there a way to set the vertex colors of the roads to default to (0, 0, 0, 1)?
    Could you add a function that exposes vertex colors for any given (arbitrary) road segment? That would be awesome.
     
  24. raoul

    raoul

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

    Road vertex colors will be used in a later version so I am not sure about setting them to (0, 0, 0, 1) by default.

    But you can do that something like this:

    Code (csharp):
    1.  
    2. using UnityEngine;
    3. using UnityEditor;
    4. using System.Collections;
    5. using System.Collections.Generic;
    6. using EasyRoads3Dv3;
    7.  
    8. public class APITestsEditor : ScriptableObject {
    9.  
    10. [MenuItem( "GameObject/3D Object/EasyRoads3Dv3/Set Vertex Colors" )]
    11. public static void SetVertexColors(){
    12. ERModularRoad[] roads = FindObjectsOfType(typeof(ERModularRoad)) as ERModularRoad[];
    13. foreach(ERModularRoad road in roads){
    14. Mesh m = road.gameObject.GetComponent<MeshFilter>().sharedMesh;
    15. Color[] colors = new Color[m.vertices.Length];
    16. Color c = new Color(0, 0, 0, 1);
    17. for(int i = 0; i < colors.Length; i++){
    18. colors[i] = c;
    19. }
    20. m.colors = colors;
    21. }
    22. }
    23. }
    24.  
    How should the second part, about exposing vertex colors, work?

    Thanks,
    Raoul
     
    Marco-Sperling likes this.
  25. Marco-Sperling

    Marco-Sperling

    Joined:
    Mar 5, 2012
    Posts:
    620
    Thx for the intermediate solution. At least the default state of my shader can be used this way where it displays the basic road texture.

    In an optimal situation I as an artist would like to paint vertex colors intuitively on the road mesh. I can already do this with 3rd party assets like vpaint (though it doesn't support Unity 5.3 and one has to fix its code by hand) or Vertex Painter by jbooth:
    https://github.com/slipster216/VertexPaint

    But since roads can change their vertex count anytime a road marker gets moved around or deleted I do not see this happening during production - this is only feasible right before making a build or publishing the game. Not exactly what you need to develop a look and very risky. I see this for final tweaks and bug fixes only.

    So what is the next most intuitive way thinking in EasyRoads terms? Markers.

    I would like to have 3 color attributes on any given marker: Start-Color, Middle-Color, End-Color where start and end colors only affect the first and last set of vertices of the segment that the given marker controls.
    Whereas the middle color defines the rest of the vertices between the two ends.
    They should default to color-triples which we can setup per road type usually using something like (1, 1, 1, 1) or (0, 0, 0, 0) for initialization.
    (1, 1, 1, 1) is good when you are using color multiplicative shader for your roads.
    (0, 0, 0, 0) is fine when you are using some kind of splat mapping shader for your roads (my situation).
    If the road segment only consist of a pair of start and a pair of end vertices no middle color gets set.

    For more control over "what is the rest" you could expose a curve. We could set it to constant 1 meaning the same as I just described. Or linear 0-1 which means a linear falloff to the vertices affected by the middle color. Or any other hand drawn curve.
    This curve would be mirror-evaluated starting from the middle of the road segment (if this isn't clear I can draw a picture).

    all the best,
    Marco

    Edit:
    A simpler solution could look like this.
    One color per marker only.
    One curve being evaluated from start to end of the segment controlled by this marker.
    Now the artist can raise the curve to 1 at both start and end if he wants to. And lower the curve to zero anywhere inbetween if he wants to have no vertex color in the middle of the segment. Or he could draw any kind of zigzag curve to turn the color on and off as he pleases.
    I think I like this simpler solution more. KISS.
     
    Last edited: Jul 29, 2016
  26. Pingu2

    Pingu2

    Joined:
    Oct 24, 2015
    Posts:
    3
    Hi !
    I have a BIG problem :
    This asset is really really fine, great job !
    But, once in Android, I have a problem :

    Could not create directory: //EasyRoads3D/RoadCreator System.UnauthorizedAccessException: Access to the path "/EasyRoads3D" is denied.
    I/Unity ( 6424): at System.IO.Directory.CreateDirectoriesInternal (System.String path) [0x00058] in /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.IO/Directory.cs:135
    I/Unity ( 6424): at System.IO.Directory.CreateDirectory (System.String path) [0x0009a] in /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.IO/Directory.cs:96
    I/Unity ( 6424): at System.IO.DirectoryInfo.Create () [0x00000] in /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.IO/DirectoryInfo.cs:141
    I/Unity ( 6424): at (wrapper remoting-invoke-with-check) System.IO.DirectoryInfo:Create ()
    I/Unity ( 6424): at System.IO.Directory.CreateDirectoriesInternal (System.String path) [0x00023] in /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.IO/Directory.cs:116
    I/Unity ( 6424): at System.IO.Directory.CreateDirectory (System.String path) [0x0009a] in /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.IO/Directory.cs:96
    I/Unity ( 6424): at EasyRoads3D.O


    I'm stuck and I have no idea of what's going on, I tried to change the manifest, but the permission is supposed to be already in.
    In my application, I don't need any backup, so, I think, no need to save anything
     
  27. raoul

    raoul

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

    Yes, painting vertex colors should always be done at the end once all your roads have been created.

    What you describe is more or less on the list. I will take your suggestions into consideration when implementing this. :)

    Thanks,
    Raoul
     
    Marco-Sperling likes this.
  28. raoul

    raoul

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

    Could you explain more about what you are doing? I am asking this because there is no code that tries to create an "/EasyRoads3D/RoadCreator" folder.

    Is this error actually EasyRoads3D related? It looks more Android read/write directory related. Are you trying to create a directory at runtime on android?

    Thanks,
    Raoul
     
    Last edited: Jul 29, 2016
  29. Pingu2

    Pingu2

    Joined:
    Oct 24, 2015
    Posts:
    3
    I think that's because I use the free version, so, v2 (I suppose)
    I'll go to the other topic, sorry =X

    I'm just copying markers to create a new road during runtime
     
  30. raoul

    raoul

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

    V2 is Unity editor only, there is no runtime functionality. There is no reason to include scripts, the "Finalize" option removes all script components from your road objects.

    In any case, also in v2 there is no "/EasyRoads3D/RoadCreator" create directory code.

    Thanks,
    Raoul
     
  31. LaverZZY

    LaverZZY

    Joined:
    Aug 11, 2014
    Posts:
    12
    Hi Raoul,
    concrete barrier sideobjects are wrong in 7.7.3 and unity3d 5.3.6, is this a bug?
     

    Attached Files:

  32. raoul

    raoul

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

    That is indeed a 7.7.3 bug. Depending on the rotation of the source prefab, this can happen after rebuilding a procedural side object in 7.7.3 or when creating a new procedural side objects (also for new road network objects).

    It is fixed in the next release. The Undo / Redo implementation for beta 8.0 seems to be stable. Before releasing it I first like to double check. I will prepare an alpha build. For those who want to try it out, please send me a PM with your email, or email me. This build also includes various recent requests like the AQUAS support for flowmaps.

    Thanks,
    Raoul
     
  33. Marco-Sperling

    Marco-Sperling

    Joined:
    Mar 5, 2012
    Posts:
    620
    Hey raoul,
    in 7.7.3 there is an issue with the road types (General Settings).
    Whenever one selects a road type from the drop-down list its road material drop-down list does not update accordingly. The material field itself does - but the list does not. This is somewhat confusing.

    And is there a way to start with a clean project without any example road types, sideobjects etcetera? I want to restrict us from accidentally selecting pre-built stuff which I know will happen and will cause us trouble in the long run.
     
    Last edited: Aug 4, 2016
  34. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735

    Hi Marco,

    The material in the material slot is the material associated with the selected road type. The materials dropdown displays all materials in /Assets/EasyRoads3D/Resources/Materials/roads/. It is just a quick way to select a road material if you drop your own materials in that folder as well. It is not supposed to update after selecting another road type. If that is confusing it can be changed so the material associated with the selected road type is auto selected, provided that this material is located in the above mentioned folder.

    The road type presets and side objects are stored in:

    /Assets/EasyRoads3D/Resources/ERProjectLog

    You can try emptying the "Side Objects" and "Road Presets" arrays in the Inspector. This will only work before creating your first road network in a new project. Otherwise you can do the same with:

    /Assets/EasyRoads3D/Resources/ERSideObjectLog

    This prefab is created after you create your first road network and will also include newly created side object and road type info.

    For the final release I have decided to only put the required assets in the main package contents (like v2 currently). An additional resources package with road types, side objects and the demo project will be part of the download and can be imported separately.

    Thanks,
    Raoul
     
  35. IFL

    IFL

    Joined:
    Apr 13, 2013
    Posts:
    408
    Awesome tool @raoul! I've been creating curbs for standard road segments and intersections by using beveled sidewalks with a width of 0.25, but the roundabouts seem locked to a minimum of 1 for sidewalk width. How should I get around that? Is there another setting that the minimum width is dependent upon?
     
  36. raoul

    raoul

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

    Thank you, glad to hear you like it!

    Up to one of the recent betas, sidewalk widths for X, T crossings were also locked to a minimum of 1. I will check this and make sure you can go lower than 1 on roundabouts as well.

    Thanks,
    Raoul
     
    IFL likes this.
  37. ekuNNN

    ekuNNN

    Joined:
    Sep 3, 2013
    Posts:
    22
    Hey Raoul,

    I think I'm probably missing something simple, but is it possible to change the width of your road when you've already created it? Or is it only possible to set the width when you do Add new road? Because when I select my road and change the width setting it doesn't work.
     
  38. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hey ekuNNN,

    What is the status of the road? Is it connected to a crossing at the start or end? In that case it is indeed not possible to change the road width directly.

    In v3 it is recommended to work with road types, each road type can have its own width. Road types can be assigned to crossing connections which will automatically update according the road type settings. It is recommended to create these road types and dynamic crossings before you start buiding the road network. This way you can quickly reuse these road types and crossings.

    You can always adjust these settings in a later stage and in a future build crossing connections will also adjust to road width changes, but at the moment this has to be done on the Road Type and Crossing connection. This initial workflow is done because that way roads pulled out of these connections will also have the correct width.

    If the road is not connected to a crossing, changing the width of the road in the Inspector should work just fine.

    Thanks,
    Raoul
     
    Last edited: Aug 12, 2016
    ekuNNN likes this.
  39. ekuNNN

    ekuNNN

    Joined:
    Sep 3, 2013
    Posts:
    22
    Ah, I had a crossing attached, that was the problem. It works fine now. Thanks for the swift reply!
     
    raoul likes this.
  40. DivergenceOnline

    DivergenceOnline

    Joined:
    Apr 19, 2015
    Posts:
    244
    EasyRoads3Dv3: Updating the heightmap of terrain WC_23 failed, please report with details!
    UnityEngine.Debug:LogError(Object)
    EasyRoads3Dv3.QDQDOOQQOOQDD:OCCODDDOCC(ERModularBase, ERTerrain, Terrain, Single, Single, Single, Single)
    EasyRoads3Dv3Editor.OOQDODCDQO:OODODDQCDD(ERModularBase, OOCOQOCCCO)
    EasyRoads3Dv3Editor.OOCOQOCCCO:OnInspectorGUI()
    UnityEditor.DockArea:OnGUI()
     
  41. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735

    Hi DivergenceOnline,

    Please note the end of the warning ".. please report with details" :)

    As a start:

    What is your situation? do you have other terrain plugins in your project?

    What is your terrain setup? Do you have more than 1 terrain in the scene? And in that case, is that the only terrain that failed updating?

    Can you notice what exactly went wrong?

    Thanks,
    Raoul
     
  42. DivergenceOnline

    DivergenceOnline

    Joined:
    Apr 19, 2015
    Posts:
    244
    I did note that, which is exactly why I'm reporting it.

    Easy Roads and World Creator, which attaches to a terrain and it'll screw everything up if i remove it, but that isn't the problem because i used easyroads on a dozen other terrains all with the same script on them last week without issue.

    Only one terrain in this scene.

    2048x2048 resolution
     
  43. raoul

    raoul

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

    I was more referirng to the "... with details" part. Everything in the warning message is pointing to the bit that prints out the warning, there is no further info about the actual problem.

    So this is a scene with a single terrain using World Creator and there is no issue with this in previous scenes also using World Creator?

    Are these terrains also 2048x2048 resolution (that is 2049x2049, is that right?)? 2049 is quite large but shouldn't result in errors. Just to double check, have you tried building with different Build settings, for example switch off "Remove Trees", "Remove Detail Objects", "Update Terrain Splatmaps" and "Add Side Object Vegetation to Terrain"? Is the problem related to one of these options?

    To see if something in World Creator is interefering, you could duplicate the project and in the duplicate remove all World Creator objects and script components from the scene so only the Unity terrain object remains. This is just to test. The other week we had a user reporting that the terrain heightmap changes were restored as soon as he clicked the Play button. It turned out to be related to a Terrain Composer option.

    Or if you want we can look at this specific scene / terrain, please email me in this case.

    Thanks,
    Raoul
     
    IFL likes this.
  44. Atzig

    Atzig

    Joined:
    Jul 17, 2014
    Posts:
    157
    Hey Raoul, not sure what happened but my road names are messed up (see the image) and the Side Object Status won't unfold, I tried deleting Easy Roads then reimporting but nothing changed, I tried the latest version as well as the latest beta. I recently imported this asset https://goo.gl/HnUx6I and had to remove it because it caused too many issues. Maybe it changed something?
     

    Attached Files:

    • cap.PNG
      cap.PNG
      File size:
      10.6 KB
      Views:
      871
  45. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Hey Atzig,

    I haven't checked if this happens on road names as well but that kind of display will also happen on road type names and side object names when your project uses Text for Asset Serialization ( Top menu > Edit> Project Settings > Editor). Here is a workaround copied from the troubleshooting page in the docs (if you indeed do need Text mode for asset serialization ) :

    Please let me know if this doesn't solve your issue.

    Side Object Status not unfolding is a 7.7.3 bug. If you need this urgently, further above on this page, http://forum.unity3d.com/threads/ea...g-new-road-system.229327/page-51#post-2725639, is some code to fix that.

    Thanks,
    Raoul
     
  46. LondonStevey

    LondonStevey

    Joined:
    Jun 26, 2015
    Posts:
    33
    Hi,
    Awesome work on EasyRoads, I'm loving how powerful and flexible it is, especially this version 3. I'm having a few issues with procedural side objects at the moment though and can't figure out what I'm doing wrong!

    I've created a prefab with exactly the same structure as the wirefence example, I can see the wireframe appearing in the mesh editor, but once I apply my changes I see nothing in the scene. If I load the wirefence prefab from your examples into my new side object i see it perfectly. I've tried taking the wirefence object, loading it into blender, modifying some vertices and saving as an object again, but when I update it from the mesh editor I see nothing in the scene again.
    Are there any rules on what meshes can be used and how they need to be created? Does it need to be saved in a certain way? Is there a tutorial around procedural meshes anywhere?

    I found that I can put any number of submeshes in as long as they are 1 deep, otherwise they don't appear in the mesh editor.
    But I have no idea why this isn't appearing, in the scene

    Also I've noticed, "Build Test Mesh" doesn't seem to provide me with the expected results, the 2 end meshes are generated with the same mesh as the middle one.
     
  47. raoul

    raoul

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

    Thank you, glad to hear you like it!

    It is hard to tell what is going wrong without more info (source mesh and the side object settings). If you want you can email me the model so I can test this myself.

    In Beta 7.7.2 extracting mesh data doesn't always work well, especially when rotations are applied to child meshes. Try for example rebuilding example side objects in the package like the barriers or guard rails. This will not work well in beta 7.7.2 which you can already see in "Build test Mesh" like you mentioned. So perhaps your issue is related?

    It looks like an update (beta 8.0) will be available within the next couple of days with a fix for this issue. So perhaps this will already work but you may want to send me the model anyway (.obj or .fbx please) so I can double check.

    As for the "rules", the side objects in the beta package serve as examples. Whether your source meshes work depends on the complexity and what you want to achieve also with regard to start / end segments. Clean start / middle / end segment structures like for the barriers can be done with a single source mesh whilst for more complex side objects like the power lines, separate start / connection / end objects are used.

    In general (and for everyone), if you are having issues with this I would recommend to post here or ideally email me with the source object, so I can recommend the best way to set this up.

    Thanks,
    Raoul

    [Edit] Just a thought, are you using a prefab for this? And if so, is that prefab centered at (0, 0, 0)?
     
    Last edited: Aug 18, 2016
  48. LondonStevey

    LondonStevey

    Joined:
    Jun 26, 2015
    Posts:
    33
    Hi Raoul,
    Many thanks for the quick reply! It was the centering of the prefab that was causing it to have issues so many thanks for that. I'm creating a skiing game and its perfect for creating the barrier and loads of other side objects, so clever the way that procedural stuff works.
    Just need to sort my tree's out now! ;)

    One other thing, I'm noticing the Add Box Collider doesn't seem to be working, is there a bug with that? It creates the colliders but they are 0 height. I tried with the wirefences as well and they do the same.

    Many Thanks

    Steve
     

    Attached Files:

    hopeful and raoul like this.
  49. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735

    Hi Steve,

    Glad to hear that! Indeed when preparing prefab with a scene instance and doing "Apply Changes To Prefab" the prefab in the assets folder also inherits the transform position. This will not work well when extracting the mesh data, the prefabs position should be at (0, 0 , 0). In beta 8.0 this is done automatically.

    Great screenshot! My initial idea for the new demo scene was a winter environment also including ski tracks. Just to show that the v3 feature set is not roads only and can be used for different purposes as well, like creating a skiing track using the terrain deformation features. The random rotations on the barrier in your screenshot look great although it could perhaps be a little bit less strong?

    Regarding trees, make sure to add them to the terrain object first. Afterwards they will display in the side object Terrain Vegetation dropdown. This type of side object will be instantiated in the scene in Edit Mode, in Build Mode they will be added as terrain tree instances.

    The Box Collider issue should be fixed as well in beta 8.0.

    Thanks,
    Raoul
     
    Last edited: Aug 19, 2016
  50. MrIntel

    MrIntel

    Joined:
    Jul 4, 2014
    Posts:
    43
    Hi im looking to buy this asset but i have a couple of questions first, Can i create roads at runtime through script? and Can i place them on a mesh and not terrain?