Jump to content
Sign in to follow this  
Imran

Prefab loses its material

Recommended Posts

Hello everyone,

 

When I make a model created by probuilder then save it in the prefabs folder or any folder in the project panel it shows it retains the material that I initially added or sometimes I have to add it myself. Then it stays there for a while, I save project, save scene and carry on probuildering my imagination into models in unity. After sometime, a particular prefab goes for a prefap I think. haha. Meaning the material in the prefab reverts to default_prototype. I thought of changing the default material in Edit/preferences/prototype since I am trying to make a game using only one material which has a texture atlas. But surely that can't be a solution. It restricts my flexibility to use other materials in unity.

 

So does anyone know anykind of way around this problem? I would like to fix it before I proceed with my game modeling in unity.

 

Btw this particular problem doesn't happen when I use primitve shapes provided by uniyt to create a prefab.

 

Regards

 

Imran.

 

Share this post


Link to post
Share on other sites

Sorry to hijack a little, karl, but I did notice that when exporting to obj and placing the obj in a scene, the mats are all quite strange and not true to the pb placement (For example, I created a house with a red roof and a brown door, with white walls and blue windows, only one small area of the door or the windows had the actual texture, the rest was the walls for some reason). Is that normal?

Share this post


Link to post
Share on other sites

This is a bug in Unity's obj importer.  Objects with multiple materials import with the first submesh intact, but subsequent submeshes only have the first triangle textured.  You can just drag and drop the appropriate material to the vacant MeshRenderer sharedMaterial slots and it should work.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×