Search Unity

Realistic Curved textured roads in 2 minutes!! ;)

Discussion in 'Formats & External Tools' started by aninjamonk, Oct 6, 2010.

  1. aninjamonk

    aninjamonk

    Joined:
    Aug 31, 2010
    Posts:
    153
    I finally figured it out!!!

    You can create a realistic road in 3ds max in 2 minutes using these steps.

    1) Create a 2D curved track (complete loop) using 2D splines line tool. (Remember to create the spline smooth, smoother the curves on spline less poly you track will be).



    2) now create a box (keep height of box nearly 0).

    2.5) Texture the box(skip this step if you are doing this tutorial for first time) with proper u-v mapping.
    Remember the u-v mapping values as you would need them in unity as well.Also Instead of rotating your u-v map in 3ds max
    rotate the texture as unity does not have u-v rotation facility.



    3) add pathDeform modifier(remember not PathDeform(WSM) to the box.

    4) pick path in the pathDeform(WSM) modifier and select the 2d spline.

    5) Select path deform axis to place it in appropriate direction.


    6) Increase the width and width segments.

    7) Now convert it into a editable mesh and there you go!!



    8) Remove the polygons on back and on sides
    > Select Ignore Backfacing in selection menu of editable mesh modifier.
    > Now select the track using selection box and invert your selection to
    select the sides and back of the road. now delete them.
    8.5) Remove the spline.

    9) Move the Vertex or Faces to shape it according to your requirement.


    10) Import the .max file in unity to create your road!!


    Congrates you have made a perfect low poly realistic curvy road in just 500 polygons :)
     
    Last edited: Oct 6, 2010
  2. SpookyCat

    SpookyCat

    Joined:
    Jan 25, 2010
    Posts:
    3,765
    Convert the mesh to an edit mesh before export that should sort it out. Have you tried using the lofter it is much better suited to making roads, much easier.
     
  3. aninjamonk

    aninjamonk

    Joined:
    Aug 31, 2010
    Posts:
    153
    no I have got no idea of lofter!!! can you brief it for me or give me some pointers regarding the same.
     
  4. SpookyCat

    SpookyCat

    Joined:
    Jan 25, 2010
    Posts:
    3,765
    Just look in the 3ds Max Help under 'Loft Compound Object'
     
  5. aninjamonk

    aninjamonk

    Joined:
    Aug 31, 2010
    Posts:
    153
    heyy!!1 i finally figured it out!! I have updated the post with proper images!!
     
  6. Rman

    Rman

    Joined:
    Jun 6, 2010
    Posts:
    147
    I cant seem to add segments using your method, adding segments to the box produces no extra length. I can add length by stretching, however then my uv's dont tile up. It may just be a uv issue.
     
  7. SpookyCat

    SpookyCat

    Joined:
    Jan 25, 2010
    Posts:
    3,765
    This really isn't a good way of doing this, use the Lofter you get total control over the whole process, you can refine the curve, add more polys, smooth sections, get proper mapping, add bumps, banking etc etc
     
  8. Greymarch

    Greymarch

    Joined:
    Jun 7, 2007
    Posts:
    106
    I've you've already got the spline, an even easier way to do this is to
    1) make a copy of the (sp)line, 2) set one of the splines to renderable in viewport and change from radial to rectangular (you can later delete the sides and bottom faces or use them to burry into terrain), 3) adjust the interpolation steps for more or fewer polys/smoothness, and 4) for unwrapping to your texture choose UnwrapUVW, select the spline button and pick your spline copy, set to planar and just tweak a bit in edit window to space them out.
     
  9. imDanOush

    imDanOush

    Joined:
    Oct 12, 2013
    Posts:
    368
  10. MikeUpchat

    MikeUpchat

    Joined:
    Sep 24, 2010
    Posts:
    1,056
    I started out a long time back like the original post trying to do my own system but gave up but then found the perfect solution for my needs on the Asset store, it allows me to build my tracks and pieces for an endless driving game with ease, has support for conforming to terrains, or carving into terrains and works so well I now have a track editor built right into my game. You can see the features below. It all works just as it does in Max which again was perfect for my needs as I knew already how to use those tools, and the exporter for max to get splines, even animated ones into MegaShapes really made it the perfect fit for my needs.


     
  11. pauloaguiar

    pauloaguiar

    Joined:
    May 13, 2009
    Posts:
    700
    Most people do that Technic, you can create an layer, copy of the track and create from that track as terrain both sides delete middle polygon, use extrude tools to extend the road terrain. and another layer and copy of the track, to create walls for example or mountains.
    Hope is a good hit;)
     
  12. djoshi

    djoshi

    Joined:
    Mar 28, 2014
    Posts:
    182
    Any one knows how to save 1 map channel with this map & save 2nd map channel for lightmap?