Search Unity

World machine to unity

Discussion in 'Formats & External Tools' started by tamilshinobi, Jan 7, 2016.

  1. tamilshinobi

    tamilshinobi

    Joined:
    Oct 8, 2015
    Posts:
    1
    I'm having trouble with importing my terrain into unity. For some reason half of my terrain is inverted, and I;m using .r16 format.
     

    Attached Files:

  2. steego

    steego

    Joined:
    Jul 15, 2010
    Posts:
    969
    That's an odd one, never seen that before. But your terrain looks rectangular, maybe that's your problem - what resolution are you generating and importing the heightmap as?

    Unity terrain heightmaps should be square with edges of a length that is a power of 2 plus one (2^n + 1), like 513x513, 1025x1025, 2049x2049 etc.
     
  3. cibbia

    cibbia

    Joined:
    Jun 27, 2015
    Posts:
    2
    Im not sure about the inverted tiles but I think you need to convert your files to .raw rather than .r16. Its easy to do in windows for batching lots of them just go to comand prompt navigate to the folder and type "ren *.r16 *.raw" and that should change them all to .raw hope this helps.
     
  4. steego

    steego

    Joined:
    Jul 15, 2010
    Posts:
    969
    You don't need to do that, just change from "raw" to "all files" in the file dialog when importing the heightmap in unity, and it will import .r16 files just fine, you don't need to rename them.
     
  5. snowcreep123

    snowcreep123

    Joined:
    Apr 16, 2018
    Posts:
    1
    Unity interprets raw heightfield origins differently from World Machine; your terrain will appear to be flipped on the Y-axis! One way to fix this is to add a Flipper device in World Machine just before your Height Output and turn on the Y-axis flip. This will make the terrain export identically.
     
  6. LAWDOG2020

    LAWDOG2020

    Joined:
    Dec 28, 2020
    Posts:
    5

    Where is the FLIPPER DEVICE in World Machine? Is it called FLIPPER???
     
  7. LAWDOG2020

    LAWDOG2020

    Joined:
    Dec 28, 2020
    Posts:
    5

    I am able to get my terrains into Unity now and I can play with the resolution but where is the FLIPPER thing thanks???