I’ve got a pretty simple mesh that I’m using, however, as you can see in the screen shot, it won’t shade in the same way as a primitive cube. Both objects have the same material on them. Any suggestions? I’m having unity calculate the normals for me, could that be the problem?
2 Answers
2The problem is the normals. Your mesh is sharing normals on edges between faces (often called “edge-smoothing”). The unity one has separate normals for each faces’ vertices.
You’ll need to fix the normals in your mesh editor before re-exporting to Unity.
They can also be changed in Unity. Select your mesh in the Project view and you can have Unity calculate normals for you. You also have the option to change the edge break angle
– Firedan1176Sorry, had to get some sleep hah. Well, the only thing I think there is that maybe you updated the instances reference to the prefab, but maybe your prefab in the Project folder has its variable still pointing at the scene object? Hopefully that's the issue... Let me know if it isn't.
– StratosomeIt turns out this is happening because I am sharing vertices. This means that the normals are pointing directly out at each corner. By having 3 vertices at each corner of the mesh I can properly direct the normals for each face.
Updated the link, and then applied the changes to the prefab. No dice! I made a quick bare bones unitypackage if you (or anyone) wanted to take a look. The loading script looks for anything tagged "Player". [Attachment][1] [1]: /storage/temp/122667-loadingissue.zip
– NeedsLoomis
Where are you making your mesh? A 3D program like Blender? If that is the case, check to see if you are using smooth edges or vertices.
– rageingnonsense