Search Unity

  1. Unity 2018.3 is now released.
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. Want more efficiency in your development work? Sign up to receive weekly tech and creative know-how from Unity experts.
    Dismiss Notice
  4. Build games and experiences that can load instantly and without install. Explore the Project Tiny Preview today!
    Dismiss Notice
  5. Nominations have been announced for this years Unity Awards. Celebrate the wonderful projects made by your peers this year and get voting! Vote here!
    Dismiss Notice
  6. Want to provide direct feedback to the Unity team? Join the Unity Advisory Panel.
    Dismiss Notice
  7. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice

Connecting different terrain heights?

Discussion in 'World Building' started by JDatUnity, Dec 2, 2018.

  1. JDatUnity

    JDatUnity

    Joined:
    May 15, 2017
    Posts:
    4
    I'm using the 2018.3 Beta to create a large slope made from multiple connected terrains. I'm having an issue where these terrains all have the same base height, meaning I can't have terrains next to eachother and use the smoothing tool to close any gaps

    upload_2018-12-2_14-4-47.png

    Here the terrain on the right has a y position of 200 and a height of 0, the terrain on the left has a position of 0 and a height of 200.

    Is there any way to get them to align properly?
     
  2. Flavelius

    Flavelius

    Joined:
    Jul 8, 2012
    Posts:
    494
  3. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    23,825
    My solution when I was working on this was unfortunately to just take the generation outside of Unity then check what each cell (terrain) lowest and highest point was and do it manually (to maximise resolution). Because if this isn't done, the terrain slowly loses precision on height. Would just try automating that if you can't find a workaround.

    If you can get away with a single higher resolution terrain it'll save tears in the long run.
     
  4. JDatUnity

    JDatUnity

    Joined:
    May 15, 2017
    Posts:
    4
  5. Flavelius

    Flavelius

    Joined:
    Jul 8, 2012
    Posts:
    494
  6. JDatUnity

    JDatUnity

    Joined:
    May 15, 2017
    Posts:
    4
    Thanks for your help but I couldn't get it working the way I wanted. For now, all terrains are using the same max height which is working fine. This is ofcourse not ideal because as soon as new terrain parts are added that need to be higher than 2000 problems will occur.
     
  7. ChrisTchou

    ChrisTchou

    Unity Technologies

    Joined:
    Apr 26, 2017
    Posts:
    38
    Yeah, this is an issue. The terrain tools assume every terrain has the same Y range, so they can directly merge the height-maps from each tile.

    It's possible to make it (mostly) work by converting the tools to work in world space at higher precision. But it's definitely a lower priority task on our backlog, because it does make the code quite a bit more complex, and it is much harder to guarantee perfect seams between neighboring terrain tiles that have different Y ranges.
     
    jelle_unity461 likes this.
  8. awesomedata

    awesomedata

    Joined:
    Oct 8, 2014
    Posts:
    645
    What if one could just convert a heightmap-based terrain to a mesh-style terrain -- Then one could use a mesh+polybrush sculpting approach to particular terrains here.

    The only difference would be how the two render (to an extent), but it would make this extra-hacky programming a moot point. This hacky way of programming is what screwed Unity's editor in the past. :/