Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice

why is unity screwing my models

Discussion in 'General Discussion' started by killerbite_, Sep 12, 2022.

  1. killerbite_

    killerbite_

    Joined:
    Sep 12, 2022
    Posts:
    7
    this doesn't happen with all but most models i bring into unity this crap happens [see image]

    why the hell is unity doing this and i know its unity because in blender the movement point is always in the center but then when i bring it into unity, unity breaks it and this happens, so how do i fix this? im getting really sick of unity breaking my models when they work in every other 3d program/engine
     

    Attached Files:

  2. CodeSmile

    CodeSmile

    Joined:
    Apr 10, 2014
    Posts:
    4,191
    Have you checked for flipped normals?

     
  3. killerbite_

    killerbite_

    Joined:
    Sep 12, 2022
    Posts:
    7
    yes i have and i have even remodeled some of the models and still the same issue, that video was one of the first i watched but it didnt help at all sadly
     
  4. Murgilod

    Murgilod

    Joined:
    Nov 12, 2013
    Posts:
    9,799
    Are you exporting to an FBX?
     
  5. killerbite_

    killerbite_

    Joined:
    Sep 12, 2022
    Posts:
    7
    yes
    modeled in blender >exported as fbx > do textures in substance painter > import fbx and texture to unity
     
  6. Murgilod

    Murgilod

    Joined:
    Nov 12, 2013
    Posts:
    9,799
    Try clicking "apply transform" in the export settings.
     

    Attached Files:

    Martin_H likes this.
  7. CodeSmile

    CodeSmile

    Joined:
    Apr 10, 2014
    Posts:
    4,191
    All I can say is there's got to be something wrong with either the input model or one of the import/export settings causing issues. It's not like Unity randomly breaks parts of meshes for no reason at all, and pretty unlikely that you've ran into a new/unknown bug with a simple model like this.
     
  8. MadeFromPolygons

    MadeFromPolygons

    Joined:
    Oct 5, 2013
    Posts:
    3,883
    Unity is not breaking your models, you are just not making them/exporting them correctly. It looks like you simply do not have geometry facing the correct way / normals facing the correct way. Either that or incorrectly applied transformations.

    But definitely this is not unitys doing. So I suggest taking this logically one step at a time and figure out using a single area of geometry that is failing to import properly, what the issue is.
     
  9. REDACT3D_

    REDACT3D_

    Joined:
    Nov 8, 2020
    Posts:
    222
    if you select the material and make it double sided does the image show up?
    if so, the face normals are flipped.
    open the file in blender and show the normal face direction.
    Screenshot 2022-09-12 095920.png
    Screenshot 2022-09-12 100012.png
     
  10. neginfinity

    neginfinity

    Joined:
    Jan 27, 2013
    Posts:
    13,337
    Normals are inverted, and the faces are looking outwards. Unity culls back-facing triangles by default.
     
    MadeFromPolygons likes this.
  11. BIGTIMEMASTER

    BIGTIMEMASTER

    Joined:
    Jun 1, 2017
    Posts:
    5,181
    standard procedures you should use when export/import:

    freeze transformations
    delete any construction history
    set pivot to 0,0,0

    If a problem occurs, show the export settings, import settings, and make a test model in the same scene, export it, and see if the same issue occurs.
     
    angrypenguin likes this.
  12. BonneCW

    BonneCW

    Joined:
    Jan 22, 2017
    Posts:
    123
    When you import more than one blend file at once Unity can mess them up (since 2021.x when they introduced multithreaded model import). Might not be your issue, but something to keep in mind. If that's the case for you you can reimport each model individually.
     
  13. killerbite_

    killerbite_

    Joined:
    Sep 12, 2022
    Posts:
    7
    no dice
    my normals arnt inverted [see image]
    i have tried applying all transforms and resetting the pivot point every option in the object menu yet nothing has fixed it even in a new scene
     

    Attached Files:

  14. killerbite_

    killerbite_

    Joined:
    Sep 12, 2022
    Posts:
    7
    no worries cheers, i tend to do one at a time but noted
     
  15. killerbite_

    killerbite_

    Joined:
    Sep 12, 2022
    Posts:
    7
    tryed to reset pivot and freeze transform but no dice even in a new scene so im a bit stumped, i ahve other models in the blender file that have exported and import just fine and there transforms arnt all the way off in one direction
     
  16. neginfinity

    neginfinity

    Joined:
    Jan 27, 2013
    Posts:
    13,337
    If you can see through the face from one side but not the other, they are.

    You also haven't provided an image t o show what it is supposed to look like.
     
    MadeFromPolygons likes this.
  17. BIGTIMEMASTER

    BIGTIMEMASTER

    Joined:
    Jun 1, 2017
    Posts:
    5,181
    @killerbite_

    so if you can successfully import a model from the same scene into unity, that confirms the import and export are good.

    Who dunnit then?

    All evidence points to the specific model. Did you use the normal viewer to check the normals?
     
    MadeFromPolygons likes this.
  18. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,519
    I'm not seeing that in the posted image. What I do see is that the pivot is about 10m away from the outlined object, so I assume that's the issue here.

    Is the issue that the pivot is indeed at (0, 0, 0) in world space, but the model's geometry is in fact ~10m away from the scene origin? This is a pretty common issue when a whole scene is constructed directly in the modelling package, rather than making individual objects and then assembling the scene in engine. If so it's not Blender or Unity specific, it's about being thoroughly familiar with world space vs. object space.

    @killerbite_, in Blender where is the object's local origin (i.e. 0, 0, 0 position) in relation to its visible geometry? I'm no Blender expert, but I believe the pivot point can be set independently of the local origin. (Someone who knows, please feel free to correct or clarify.)
     
    MadeFromPolygons likes this.
  19. spiney199

    spiney199

    Joined:
    Feb 11, 2021
    Posts:
    6,008
    You definitely can. Unless it's changed (and it probably has in recent versions) the short-cut was SHIFT-CTRL-ALT-C to set the pivot point in object mode to one of a few options, such as cursor, local, etc.

    Heinous shortcut but one you'll use very often.
     
  20. neginfinity

    neginfinity

    Joined:
    Jan 27, 2013
    Posts:
    13,337
    I'm seeing windows floating mid air and no wall.

    OP needs to explain what the problem is.
     
  21. EricFFG

    EricFFG

    Joined:
    May 10, 2021
    Posts:
    176
    Blender exports / Blender FBX export is notoriously bad compared to other softwares
    You need to make sure to apply your transforms and do all the settings correctly
    Unity FBX import works very reliably, Blender has a really bad and error prone and confusing approach to transforms
     
  22. killerbite_

    killerbite_

    Joined:
    Sep 12, 2022
    Posts:
    7
    hey all thanks all for your help i found the issue and boy do i feel dumb, the model was a distance away from 0,0,0 in blender so that translated over to unity i didnt realize this as some files i have, have multiple models lined up as i modeled them and most others are just single files, so lesson learned always export with the model at 0,0,0 in blender and not just zeroing out the point on the model XD
     
    Ryiah and angrypenguin like this.
  23. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,519
    Don't sweat it, this happens to most of us early on.

    You don't need to bring the model to the scene's 0,0,0, you can certainly set it's local origin point. I did it with a bunch of stuff just recently, but unfortunately had to look it up myself and can't remember how. Maybe @spiney199 can point you in the right direction?
     
  24. spiney199

    spiney199

    Joined:
    Feb 11, 2021
    Posts:
    6,008
    As I've late I've been using this plugin: https://github.com/EdyJ/blender-to-unity-fbx-exporter which should smooth out the process a bit, though I haven't done much 3d lately.

    I believe it can properly handle objects that aren't centred on the world origin, whereas the default exporter will always offset your model by it's current world offset. Could be wrong; the 'Apply Transform' option might be able to handle this.

    Mind you I try to always export my models centred on origin, just out of habit from my days modding games. Nowadays in Blender you aren't limited by the number of layers you used to be given, so you can make any number of collections if you're the sort to make different variations and whatnot in the same .blend file.

    If you are making somewhat elaborate set-ups like houses and buildings, child them all to an empty and keep that empty at world origin.

    Anyway I'll stop rambling.
     
    Ryiah likes this.