- Home /
Problem importing assets from a unitypackage
Hello.
I've got a series of assets on one PC that are built in max. I bring these in to unity fine and lay them out in a scene. I then export these items into a unitypackage using the export function.
I take the unity package over to another computer and import the package. All models show up, but every single model is missing its previously assigned textures. I can drag the model into the scene and they're showing up pure white, and all materials are "missing".
What am I doing wrong? All materials/textures/assets are being exported when I do the export...
Answer by StephanK · Nov 09, 2010 at 05:19 PM
What did you export? Try to either export the scene file or make prefabs of the correctly setup objects and export those. Be sure to "include dependencies" in the export dialog.
I exported everything in the scene. Aren't the correctly setup objects already prefabs? I did make sure "include dependencies" are checked. Thanks.
They're "models", which are simiar to prefabs, but they are not. Did you export "everything in the scene" or "the scene"? Could be a difference.
I've tried both. I even tried exporting just the individual models (from the project tab) themselves.
Answer by Ben 16 · Mar 09, 2011 at 07:11 PM
I am having a similar problem. Our artist builds things in max, imports into Unity and then exports a package of the folder containing prefab, fbx import and all dependencies. When I open them in unity everything imports, but the textures aren't assigned to the materials correctly. The materials are there with shaders and lightmaps, just the main texture is falling off, even though it is imported. Not a major thing on something small, but when importing an entire scene it's a nightmare to go through each shader and have to re-set all the textures. Thing is that it seems to be only me that's experiencing this, my other colleagues don't tend to have the same problem, but we can't see any reason for something being different???
I ended up switching over to the .fbx files from max ins$$anonymous$$d of trying to mess with Unitypackages. You can drag the .fbx into the assets folder and Unity will automatically assign everything. I could never get the textures to assign correctly the other way and it became too much of a problem. I haven't had this issue with just importing the .fbx alone however.
yeah that's the problem though, the artist is doing what you describe above, but then he has to get the stuff to me, and the most sensible way to do that is with unity packages. I've discovered that it happens when I'm importing a new package that contains textures that one I already have unpackaged into my project. The solution I have just now is to just unpackage, build my asset bundle, and then delete as I go along.
Answer by Favo-Yang · Apr 07, 2011 at 07:17 AM
I got the same issue and consider that's a bug for Unity. However, as a work around - create all your fbx instances to prefab. Prefab can be export / import with correct textures references.
Your answer
Follow this Question
Related Questions
How to fix imported materials 1 Answer
How to update imported assets from a unity package? 3 Answers
Where did the materials properties go? 0 Answers
Creating a Material from shader string 2 Answers