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 Claytonious,

    This has been further optimized. Please let me know if you like to try an alpha build.

    I also made a note for v3.x to display these connector matches in the 3rd connector tab in the case a road marker is selected (like what you did in your first movie) with still the option to show all connectors in that same tab. This will clean up the Inspector options for the selected road a little bit as well.

    Thanks,
    Raoul
     
  2. Deleted User

    Deleted User

    Guest

    I'm using v3 with 2017.1.1p2, and I am unable to get bridges to work. Even in the "scene main" demo scene, if I simply hit "refresh" the pillars go away and I can not figure out how to get them back. Any ideas what is going on?
     
  3. raoul

    raoul

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

    Do the pillars not appear on the example bridges already in the scene or on new bridges? I just had a quick look at this scene, the pillars side object seems to work fine.

    This side object is by default switched off for all markers. Could that be the problem? Is it active for the markers that are part of the bridge? If so, could you check the specific road object in the hierarchy and see if there are any child objects generated? That is where the pillar objects should be.

    Thanks,
    Raoul
     
  4. Deleted User

    Deleted User

    Guest

    Two different circumstances:

    1. Pillars appear in the "scene main" upon opening. But when I select "Bridge 01 2 Lane 007", then in the Inspector under "Side Objects Status > Bridge 01 Pilar" click the button "Refresh Side Object", all pillars disappear except 1. I can not figure out how to get them back. I've toggled the "Active" check box below "Selected Side Object", but nothing changes.

    2. In a fresh scene, I add a new road of type "Bridge 01 two lane" or "Bridge 01 single lane". The road builds, but there is only 1 pillar. They are toggled "Active". There is only 1 "Cylinder01" in the hierarchy.


    Other side objects such as the guard rails work. The wall does not seem to be working, but I have not really tried the wall yet.

    I am also getting this error periodically:
    "Broken text PPtr in file(Assets/EasyRoads3D/Resources/dynamic prefabs/Default X Crossing.prefab). Local file identifier (118426) doesn't exist!
    UnityEngine.Resources:Load(String)
    EasyRoads3Dv3Editor.OCQDDOCQCO:GetMatchingPrefabs(ERModularRoad, String[], Int32)
    EasyRoads3Dv3Editor.ODCOCQDDDO:OnSceneGUI()
    UnityEngine.GUIUtility: ProcessEvent(Int32, IntPtr)
    "

    This is on a Mac, if that makes any difference.

    Thanks!
     
  5. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    I just created a new project with a fresh beta 8.6 import.

    1) "Bridge 01 2 Lane 007", "Refresh Side Object" does work for me and the pillars do update after moving a marker.

    2) For me no pillars are added at all when creating a new road of type "Bridge 01 two lane". This is because the pillar side object is by default inactive on all road markers. This by itself could be confusing because you do want these pillars to build for this road type. This pillar side object can however also be used on the Simple Bridge side object which will only be active on a few markers. Probably two different pillar side objects should be used to cover both situations.

    But when toggling on "Default active state for each marker" for the pillar side object in the Side Object Manager, the pillars are added after creating a new road of the same bridge type. So that seems to act as expected.

    In any case, something else seem to happen on your end. Which beta are you using? You can see that in the most right tab. And if this is the latest beta, was it imported in a new project or did you upgrade an existing project? I do remember issues with these pillars not updating in an older beta.

    I don't think this is specifically Mac related.

    The error/warning is more Unity related, search on "Broken text PPtr in file". I belief it is package import / upgrade related but harmless and it will only appear once just after the package import. In your case the message points to the "Default X Crossing" asset. Does it instantiate well in the scene from the connections tab (3rd tab from the left in the Inspector)? And can you connect roads etc.?

    Thanks,
    Raoul
     
  6. Deleted User

    Deleted User

    Guest

    I'm using beta 8.6.. latest available in the Asset Store. Default X Crossing works properly.
     
  7. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Is this in a new project with a fresh v3 import?

    What is the status of "Default active state for each marker" in the Side Object Manager for: Bridges > Bridge 01 Pilar?

    And what is the value for "Distance between objects" further below in the Control Settings?

    Do the lamppost (in the Props tab) side objects work correctly? They have a similar setup as the pilar.

    Thanks,
    Raoul
     
  8. Deleted User

    Deleted User

    Guest

    I've played around with things some more, and have been able to get it to work. It seems that some of the toggles in the inspector do not update, so they need to be toggled on/off/on. You can witness this if you toggle off/on the pillars on a bridge in your "scene main". The pillars do not show up again when toggled on, but the "Active" toggle is still active. For some reason I have to select a few markers at once and toggle on/off/on to get them to show up again.

    But in a fresh scene I have been able to get the pillars to work. You are right that the pillars are inactive by default, which causes some confusion (to me anyway).
     
  9. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    After your last message I played around with it more as well.

    All good when the active state is on for all markers in the side object manager.

    When this is off in the side object manager, the active state on markers does update after deactivating/reactivating the side object on the road but there is a visual glitch. This is what I see, if the side object is active on the last marker (which has no affect unless it is a closed track) it will still be active after deactivating/reactivating the side object for that road. The same for the selected marker, it seems “Active” is on as the checkbox is checked. But after deselect > reselect that marker, the side object active state is displayed as switched off as it should be. The active state for all other markers is displayed correctly after deactivating/reactivating the side object for that road.

    I think this is perhaps what caused the confusion? Or is this exactly what you meant in your last post?

    But for sure there is a small visual glitch here, thank you for reporting this!

    About that active state being switched off by default in the side object manager, that is because what I already wrote in my previous post. There are several bridge types in the package. Some are active by default on all markers some not. But there is only one pillar side object which is used on all these bridges. In your own scenes you probably want pillar side objects per bridge type with a similar active state. The current demo scene is provisional and will be obsolete soon. This will be setup correctly for the new side objects.

    Thanks,
    Raoul
     
    hopeful likes this.
  10. Deleted User

    Deleted User

    Guest

    I believe that caused the confusion.
     
  11. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Ok, glad to hear this isn't a serious issue. It looks serialization related. I will check that.

    Thanks again,
    Raoul
     
  12. IsDon

    IsDon

    Joined:
    Feb 27, 2015
    Posts:
    35
    Thanks Raoul,

    I believe I was probably at about 8000 units, as I did have to extend the camera clip to 10k. I will have a play with Max RayCast - thanks heaps :)
     
  13. raoul

    raoul

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

    Sorry, what I meant was that the raycast distance is a fixed value of 5000, so please for now stay within that distance from the terrain when adding markers. But we can increase this value or add an option in General Settings > Scene Settings to customize this distance.

    Thanks,
    Raoul
     
    hopeful likes this.
  14. Deleted User

    Deleted User

    Guest

    Is the retaining wall in this image a side object that comes with this asset?



    If so, I am unable to find it.

    Thanks!
     
  15. raoul

    raoul

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

    The screenshot (and the other images on the previous page) is taken from the new demo project which is almost ready. It will be available very soon together with a new website with tutorials covering everything in the demo scene, including this retaining wall which is one of the new side objects.

    Thanks,
    Raoul
     
    Last edited: Sep 26, 2017
    Deleted User likes this.
  16. username132323232

    username132323232

    Joined:
    Dec 9, 2014
    Posts:
    477
    Hi Raoul! I need to build a fence around a large village. Can I use EasyRoads3D v3 for that? I guess it would be a road with a fence side object but no actual road?
     
  17. raoul

    raoul

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

    Yes, that is possible.

    You can create a new "road" object as a side object only, no road will be created. Instead you can activate any side object like a fence, wall, tree lines, etc.

    You can also set up new "road" types for this in General Settings > Road Types. Name it "Fence", mark it as a side object and activate the fence side object. This new "Fence" object will now be available in the list of road types, the fence side object will be build automatically as you add markers in the scene.

    Here is an example from the demo scene with manual rotations applied. This is a fence object only, aligned with the gate.

    manualRotations_.jpg

    Thanks,
    Raoul
     
    Last edited: Sep 26, 2017
  18. username132323232

    username132323232

    Joined:
    Dec 9, 2014
    Posts:
    477
    Thanks Raoul! One more question. I haven't used v3 yet, so will probably need to budget some time to learn it. I noticed that youtube video tutorials are 2-years old. Are they still relevant? I don't mind waiting a couple of months for new videos if necessary.
     
  19. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    The name of some controls may have changed and more options have been added but in general the videos are still relevant. They will be replaced for new tutorials. Meanwhile please ask if you have questions :)

    Thanks,
    Raoul
     
  20. Deleted User

    Deleted User

    Guest

    Hi Raoul,

    EasyRoads is great! I have a feature request. Would it be possible to allow us to export the road obj's as quads instead of triangles? Part of my workflow is to take the roads into an external 3D app to cut them up and subdivide them for optimization/lods/occlusion/batching. It is a bit of a tedious step to manually convert the triangles, and the automatic quadrangulation processes in the 3D apps never work right.

    Thanks!
    Shawn
     
  21. raoul

    raoul

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

    Thank you, glad to hear you like it!

    I will make a note of the export as quads. Meanwhile, have you you looked around? Perhaps one of the .obj scripts already has that option.

    Thanks,
    Raoul
     
  22. Deleted User

    Deleted User

    Guest

    There may be a script, but you have the advantage of knowing which edges to delete (or never add in the first place). The automatic quadrangulation scripts usually guess wrong. I am assuming you initially build the roads with rectangles, and then triangulate those.. forgive me if I misunderstand.
     
  23. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Triangles are used and first thoughts would be to simply get the indexes per two triangles and generate the quads accordingly. But you might have a point here. I am not sure if Mesh.Optimize() actually affects the mesh.triangles array or if this is an entirely internal triangle optimization process. I will have to look into that.

    But if you do find a script that exports to quads you may give it a try.

    Thanks,
    Raoul
     
  24. username132323232

    username132323232

    Joined:
    Dec 9, 2014
    Posts:
    477
    The video titled "Unity - EasyRoads3D v3 non roads related side objects workflow" explains exactly what I was looking for. Thanks!
     
    raoul likes this.
  25. Claytonious

    Claytonious

    Joined:
    Feb 16, 2009
    Posts:
    904
    Still no joy with the editor, but my ultimate goal is to create roads programmatically anyway, so I stopped trying that stuff. But now when I try to create a simple road with a connection on the end, it doesn't seem to work correctly: the connection isn't oriented to the road junction at all.

    Here's the simple code snippet:
    Code (CSharp):
    1. ERRoadNetwork network = new ERRoadNetwork();
    2. List<Vector3> markers = new List<Vector3>();
    3. markers.Add(transform.position);
    4. for (int i = 0; i < 3; i++)
    5. {
    6.     markers.Add(transform.position + Vector3.right * 40.0f);
    7. }
    8. ERRoadType roadType = network.GetRoadTypeByName("1. Default Road");
    9. network.SetRaiseOffset(1.0f);
    10. var road = network.CreateRoad("Highway1", roadType, markers.ToArray());
    11.  
    12. var connection = network.GetSourceConnectionByName("Default T Crossing");
    13.  
    14. road.AttachToEnd(connection);
    15.  
    And here's the result:


    Why is the crossing misaligned? Am I skipping a step?
     
  26. raoul

    raoul

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

    Would you mind explaining this further?

    Regarding the API code, the way markers are added in the code snippet they end up at the same position and therefore the direction cannot be calculated, resulting in the wrong alignment.

    Code (csharp):
    1. markers.Add(transform.position + Vector3.right * 40.0f * i);
    2.  
    3. instead of
    4.  
    5. markers.Add(transform.position + Vector3.right * 40.0f);
    Thanks,
    Raoul
     
    Last edited: Sep 28, 2017
  27. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Yes, there are some fences as well. These are provisional examples. They are useful to get familiar with using side objects in the scene and you can see the setup in the side object manager. I belief the fences are aligned with the left / right side of the road. In the side object manager you can change that to the center which will probably be better in your case. You can create your own fence side objects too.

    Thanks,
    Raoul
     
  28. JamesWjRose

    JamesWjRose

    Joined:
    Apr 13, 2017
    Posts:
    687
    Ok, I'm sure this is going to be something I am doing but...

    I am attempting to create a T Intersection based on this video:
    but when I get to the step at 1 min and 15 seconds, when I check off "T Crossing" Unity effectively locks up. One time I left it running for over 30 minutes and it was using approx 15% to 18% of CPU (it fluctuates, leaving me to think SOMETHING is happening) I have attempted this multiple times, reboots included and it continues to be an issue. I even started another new Connection object to see if maybe the first one was corrupted.

    I am running EasyRoadsDE version v3.0 Beta 8.5.1 on Windows 10, 64 bit and 16gb ram. It's a good system.

    Thoughts?
     
  29. raoul

    raoul

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

    Does this indeed happen in exactly the same situation as in the video where a new dynamic crossing is created and the changes are done on the source prefab? Or is this related to a crossing in the scene with roads attached?

    Switching off/on "T Crossing" by itself is an instant process. I just tested this, it seems to work as before.

    Does this only happen for the "T Crossing" checkbox? Does the crossing update fast for all the other options, the sidewalks, the resolution slider and the various connection and corner/sidewalk options?

    Thanks,
    Raoul
     
  30. Deleted User

    Deleted User

    Guest

    I would like to change the sub segments on some existing roads I have created, but the "Sub Segments" setting is greyed-out and not editable. Is there a way to change Sub Segments on existing roads?

    I've also tried changing the Sub Segments in Settings>Road Types>Road Type>Sub Divisions.. but when I hit "Update Scene Instances" nothing in the scene is updated. Is this a bug, or am I using it incorrectly?

    Thanks!
    Shawn
     
  31. raoul

    raoul

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

    Sub Segments is greyed out as soon as the road is attached to crossings. Is that the case in your scene?

    For custom prefabs based on your own crossing meshes, the subdivision can be added to the crossing mesh. The roads will inherit that shape, including the subdivision.

    In v3.x dynamic crossings will be updated to support subdivision as well.

    Meanwhile you can use an I Connector. I Connectors do support different road shapes. So if you insert I Connectors at both ends of the road section that needs subdivision, "Sub Segments" for the section in between the I Connectors will be enabled.

    Thanks,
    Raoul
     
    Last edited: Sep 30, 2017
  32. Deleted User

    Deleted User

    Guest

    I am using custom prefab crossings, so that is the issue.

    Thanks!
     
  33. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    Ok, in that case adding the subdivision to your custom crossing models is indeed the best way to go unless you only need it on some short sections in which case the I Connector solution will work. The further improvements on this in v3.x are more built-in dynamic crossing system related.

    Thanks,
    Raoul
     
  34. JamesWjRose

    JamesWjRose

    Joined:
    Apr 13, 2017
    Posts:
    687
    Raoul,

    Quick response! Impressive! Thank you.

    I tried again today with the following results:
    * Unchecked the SIDEWALKS - > Enabled by Default. This took a few seconds, but worked fine. Checking it again worked fine as well
    * Sidewalk height and curb width worked, but a little slow to respond.
    * Curb Width is really responding slow.
    * Unchecked "Uniform Corners" and that responded quickly, effectively instant.

    It was at this point that I attempted to check the "T Crossing" again, and again Unity's CPU usage when to 15 to 18% usage and stayed there until I hit End Task in Task Manager. I waited 20 minutes today to insure that it wasn't stuck.

    I did today's test EXACTLY like the video, including the name of the object.

    I only have one road in my game, atm, and before today's test I unchecked it in the Inspector. So only the terrain and a couple of buildings where in rendering in the project.

    So, I restarted Unity, opened the project and this time, before I selected the "T Crossing" checkbox I had saved the project. When I reopened I saw that there was an error reported in the Console. (yay, info!)




    -------
    Error:

    StackOverflowException

    UnityEngine.Object.GetInstanceID () (at C:/buildslave/unity/build/Runtime/Export/UnityEngineObject.cs:31)
    UnityEngine.Object.IsNativeObjectAlive (UnityEngine.Object o) (at C:/buildslave/unity/build/Runtime/Export/UnityEngineObject.cs:134)
    UnityEngine.Object.CompareBaseObjects (UnityEngine.Object lhs, UnityEngine.Object rhs) (at C:/buildslave/unity/build/Runtime/Export/UnityEngineObject.cs:98)
    UnityEngine.Object.op_Equality (UnityEngine.Object x, UnityEngine.Object y) (at C:/buildslave/unity/build/Runtime/Export/UnityEngineObject.cs:253)
    EasyRoads3Dv3.ERModularBase.ODOOODCOOQ (UnityEngine.Vector3& pos)
    EasyRoads3Dv3.OODDODODQC.OCCOOOQCCQ (EasyRoads3Dv3.ERCrossingPrefabs scr)
    EasyRoads3Dv3.ERCrossingPrefabs.ODDDQOCCQO (Boolean ignorePriority, EasyRoads3Dv3.ERModularRoad road)

    !! THIS IS JAMES HERE, the line above is repeated multiple times (50+) before it says "<message truncated>"

    EasyRoads3Dv3.ERCrossingPrefabs.ODDDQOCCQO (Boolean ignorePriority, EasyRoads3Dv3.ERModula<message truncated>


    -------------------------------------------------------------

    So, I did a little reading on the error, the function is simple enough. Get me an int value. I opened Visual Studio and run a Build -> Clean and then a Build -> Rebuild and got now errors. Another odd thing, I do not have a "C:\buildslave\.." folder, hidden or otherwise.

    Do you think removing your asset from my game and re-importing it?

    I feel like the answer is right in front of me, I am going to take a break today and I promise to let you know if I have any more thoughts, clues.

    I do not expect a response this weekend, enjoy your time/life. This is NOT urgent.
     
  35. raoul

    raoul

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

    Yes, you could try this in a new fresh project with only EasyRoads3D imported.

    I am still not entirely sure about the first thing I asked. Is this related to an entirely new crossing prefab you created from the crossings section in General Settings, or is this related to a crossing in the scene with a road connected? You wrote you followed the exact steps. The problem is that so far I have not heard any issues with this process, no errors, no delays. How can this be reproduced?

    If this is related to a crossing in the scene, can you disconnect the road and try again. Does that work better? And also in that case, what sort of road is attached? Is it as long road, are side objects involved?

    Thanks,
    Raoul
     
    Last edited: Sep 30, 2017
  36. AndrewBeers

    AndrewBeers

    Joined:
    May 28, 2015
    Posts:
    13
    I know how to create my own road material as shown below.
    upload_2017-10-1_13-58-3.png
    I would like to understand how to import my own mesh and use it on my own roads like the bridge road uses below. I found how to use my own meshes for intersections but roads I can only find how to change the material. Is this possible to do?

    upload_2017-10-1_13-50-17.png
     
  37. raoul

    raoul

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

    The bridge overpass road type in your second image is created in the Custom Prefab window. You mentioned that you figured out how to import your own mesh intersections. In that same window you can turn connection data into road types. That way you can create new roads with that same shape directly from the New Road Object tab and you can assign side objects to that road type, like the pillars for the bridge overpass road type in your image.

    See the below video. At 0.54 the connection is created, at 1.00 the new road type is created. The same process for the road section at 1.32 and 1.42



    But in any case, also without creating these road types, the attached road will automatically inherit the shape of the connection. Like when you pull out a new road from the bridge overpass prefab.

    Or did I misunderstood your question?

    Thanks,
    Raoul
     
  38. JamesWjRose

    JamesWjRose

    Joined:
    Apr 13, 2017
    Posts:
    687

    Raoul,

    JUST to keep you up to date. I have tried this with a couple of new projects. Once pulling down 2.5 from the asset store and then upgrading to 3, then another new project where I start with v 3.

    The error happens the MOMENT I place the new T Crossing on the terrain.

    -------------------
    This error

    StackOverflowException
    UnityEngine.Object.GetInstanceID () (at C:/buildslave/unity/build/Runtime/Export/UnityEngineObject.cs:31)

    -------------------

    Which means that the issue is upstream from selecting the checkbox. I am researching why I am getting this issue, and since I don't have a "C\buildslave" folder I am assuming that the lack of, or something to do with this is where the problem is....

    I'll report back tomorrow (Monday)
     
  39. raoul

    raoul

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

    Have you tried adding objects to the scene from the Crossings / Connections tab (3rd from the left). Does that work well? And can you change that crossing without delays after clicking the "Select Connection in Hierarchy" button?

    THanks,
    Raoul
     
  40. TriCoachSim

    TriCoachSim

    Joined:
    Mar 1, 2017
    Posts:
    22
    Hi Raoul,

    When building my game, it appears that several textures I don't use are included in the build although they are not in a Resources folder
    Example (shown in Editor log after build ) : "5.3 mb 4.9% Assets/EasyRoads3D models/textures/Motorway_2L_Bridge1.tga"
    Is there a way to prevent that or should I remove textures 1 by 1, checking those that I don't use or not?

    Thanks
     
  41. raoul

    raoul

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

    The beta package includes various custom connection prefabs and side objects. The main road network will have references to these assets unless you remove them (road types, side objects, etc). But also connection prefabs in the Resources/custom prefabs/ and Resources/dynamic prefabs/ folders.

    For example, "/Motorway_2L_Bridge1.tga", this texture is used on the respective bridge side object example. Is that side object still present in the side object manager under the Bridges tab?

    The final v3 package will not include these assets. Instead you can import those example assets that you want to use in your own project.

    Thanks,
    Raoul
     
  42. TriCoachSim

    TriCoachSim

    Joined:
    Mar 1, 2017
    Posts:
    22
    Motorway_2L_Bridge1 is indeed present in the RoadNetwork "Sides Object/Bridges" tab.
    Thank you for your quick reply

    Mika
     
  43. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    If you want to remove this side object, please make sure to also remove it afterwards from the project side objects:

    Side Object Manager > "Manage Project Side Objects" button

    Thanks,
    Raoul
     
  44. JamesWjRose

    JamesWjRose

    Joined:
    Apr 13, 2017
    Posts:
    687
    I have spent a number of hours attempting to find out why Unity is reporting an error in a file that does not exist, driving me nutty.

    So, I opened up one of the test projects that only had the new T Crossing, the Console was not reporting an error until I the INSTANT I selected the new T Crossing in Hierarchy. Then got the stated error.

    I deleted that T Crossing and added an existing T-Crossing from the 3rd tab/button as you mentioned. I then unchecked and rechecked the "T Crossing" checkbox multiple times and the response was instant and without error. I also unchecked/rechecked and affected other properties with no issues.

    Are we having fun yet?

    I am still stuck on the issue that Unity is reporting that error in a file and folders that do not exist. I have been a software developer, not game developer, for 20+ years and this FEELS like a big clue. (but hey, I have been wrong before) Searches about this folder come up with lots of responses, but nothing about the fact that it does not exists.

    Thanks again for the responses. I will continue to attempt to find more info.
     
    Last edited: Oct 2, 2017
  45. raoul

    raoul

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

    Ok, so instantiating and changing exisiting crossing prefabs all works fine.

    I have been looking around as well but cannot find anything related.

    Since this has not been reported before and I cannot recreate it, we can try to debug this. Can you send me a PM with your email if you want to do that?

    Thanks,
    Raoul
     
  46. AndrewBeers

    AndrewBeers

    Joined:
    May 28, 2015
    Posts:
    13

    Thanks for the incredibly quick reply! Your reply was very helpful. I now have a different issue that I am trying to solve. I created this new road with sidewalks extruding from my intersection that I made with sidewalks. These are all prototyping objects so please forgive the lack of detail. My issue now is that it appears that the base level for the road has been made the top of the sidewalk instead of the bottom of the road. This makes the road seem as though it is under the terrain and the sidewalks above. Is it possible to adjust where the understood bottom of the road is? Also, I added a sphere in there to show how the sidewalk is not flush with the terrain. I believe I could solve this by simply making my mesh have an outer edge the extends downward beyond any likely terrain height. Please let me know if that sounds good or if there is something built in I am not taking advantage of. Thanks again for your help!!

    upload_2017-10-3_14-41-10.png
     
  47. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,735
    The terrain will leveled relative to y = 0. So if the road segment is below y = 0 it will indeed appear below the terrain. The road sections in the example prefabs for the custom crossings system are all just a little bit above y = 0.

    Due to the grid based nature of the unity terrain object it is pretty much impossible to level the terrain with the sidewalk in general unless the sidewalk width covers two times the terrains heightmapscale. First the terrain must be leveled with the road, this requires at least 1 terrain point next to the road. Second, below the sidewalk another terrain point must be leveled with the sidewalk height.

    For sidewalks in the dynamic crossings system you have two options. No outer curb, like in your screenshot. This is for city environments. Or sidewalks with outer curb, the lower part of the outer curb is at y = 0. The terrain will be leveled to that height so there is no need to go lower.

    Thanks,
    Raoul
     
  48. JamesWjRose

    JamesWjRose

    Joined:
    Apr 13, 2017
    Posts:
    687
    Hello peoples,

    Raoul has been attempting to help me with an issue with intersections, see post 3238774. Turns out I got something wrong in the process. Let me state this again; **I** got something wrong.

    The process after creating the T Crossing in the Inspector is to Shift+Click in the game to place the new T-Crossing. In the video the folder is shown (Resources/Dynamic Prefabs) and **I** took it to mean drag n drop the asset (wrong!) This is why the error occurs.

    Raoul has been great and very responsive in the past few days in the attempt to track this down and he deserves credit for not only a good asset, but for great support of it.
     
    hopeful, IsDon and AndrewBeers like this.
  49. AndrewBeers

    AndrewBeers

    Joined:
    May 28, 2015
    Posts:
    13
    Not having the edge of the road contact the terrain seamlessly kinda bugs my perfectionist side but I totally understand why that would not be possible. For what I am using it for I think this will be fine. The y = 0 clue was very helpful once again and I was able to get the road to not be sunken under the terrain :). After getting that to work I tried dropping a texture onto the road to find that the intersection and the road coming from it seem to have different uv mapping. As you can see below the intersection and the road have the same material but they do not line up. Any idea what is happening here? .... and I swear once I figure this out I will stop bugging you!

    upload_2017-10-3_17-4-22.png

    The intersection as seen in blender.
    upload_2017-10-3_17-8-18.png
     
  50. AndrewBeers

    AndrewBeers

    Joined:
    May 28, 2015
    Posts:
    13

    I think I may have figured it out. There appears to be a uv editor option in the connection prefab creation window.. It seems to work swimmingly! Thanks anyway..