I’m having issues exporting a Blender file into Unity. Specifically, I’m encountering problems with materials and textures, as I often have to reassign them after import. Additionally, when dealing with models that have multiple materials or textures, Unity only imports them with a single material. Does anyone have any tips for exporting Blender files or advice on importing files into Unity?
I haven’t worked much with unity yet, but I just copy the blend file into the project folder and then let unity handle it by just pulling it from the assets list. I always use single material in unity with image textures. I just bake multiple materials to a single image by baking diffuse with indirect and direct unchecked. I haven’t even tried multiple materials.
I’m also not that familiar with Unity, but a big part of the problem is that all game engines (except UPBGE, but that has its own issues) have an extremely limited capability to reproduce Blender’s procedurally-generated materials. In short, Unity’s shader graph doesn’t play nice in the sandbox with Blender’s material nodes, even when nodes of the same name exist in both systems. Even the PrincipledBSDF node isn’t a perfect 1-to-1 comparison as far as I know, and that’s far from the only problem. Usually the solution is something along the lines of baking Blender’s material as a texture and then importing that into the game engine.
This topic should offer some guidance on exactly what you can do in your situation:
https://www.reddit.com/r/Unity3D/comments/x6pv9r/how_to_transfer_materials_from_blender_to_unity/
Have fun!
Is it not so to have the textures in the same map (folder) as the .blend
file?
Or is that the old way?
What I’ve been reading is that basic materials like solid albedo and (a lot of? most? probably not all) PBR will likely work automatically, and this is because Unity does recognize PrincipledBSDF. For anything that needs to be baked, the “correct” way is to bring those textures into Unity, then use Unity’s own shader graph (which is basically the Shading Workspace) to rebuild the textures into usable Unity materials. The process wouldn’t be much different in Godot.
It’s quite possible that the most straightforward way to import the textures is to have them in the same folder as the .blend, just as you said (especially if we’re talking about different maps for the same material - normal, diffuse, etc.), but I have no experience with this in Unity. In Godot it wouldn’t be strictly necessary, not least because you can use the same material on multiple meshes of different .blend files, so the game engine’s file hierarchy doesn’t “link” the material asset to the mesh asset in any way. That’s a pretty common concept as far as I know, so I would imagine Unity works that way too, but I have no idea =)