0
\$\begingroup\$

I'm a beginner at Unity and so I apologise if I'm asking a really stupid/simple question.

I have a number of 3d objects that were exported from a Blender project an then imported into Unity.

I grabbed the texture out of Blender and reapplied it in Unity.

Now I want to apply separate textures to each of the Prefab objects, but when I do, the texture change applies to all the prefabs. Likewise, if I try to duplicate one of the prefabs and apply a different texture, it applies to all of the prefabs.

Can I separate the prefabs so that I can apply individual textures to each?

Do I have to reimport the objects individually?

\$\endgroup\$
  • 1
    \$\begingroup\$ Did you remember to duplicate the materials before setting new textures on a (potentially shared) material? \$\endgroup\$ – DMGregory Jul 14 at 23:06
  • \$\begingroup\$ I did not. Do I need to create a different version of the Material for each object? Can I do this in Unity or do I have to go back to Blender? \$\endgroup\$ – Dunderklumpen Jul 14 at 23:42
  • 1
    \$\begingroup\$ You can do this in Unity, or you can use a MaterialPropertyBlock via script if you prefer. \$\endgroup\$ – DMGregory Jul 14 at 23:43
  • \$\begingroup\$ That makes a lot of sense now that I think of it. \$\endgroup\$ – Dunderklumpen Jul 15 at 2:02
  • 1
    \$\begingroup\$ If you try it and it works, feel free to post an Answer describing the steps you took to solve the problem. Or, if you get stuck, edit your question to detail what you've tried and where the results are differing from what you want. \$\endgroup\$ – DMGregory Jul 15 at 2:06
1
\$\begingroup\$

Thanks to a great comment by @DMGregory who put me on the right answer for this.

It was simply a matter of creating a new material for the Objects that I wanted to change the texture on.

The easiest way (for me) to do this was to:

  1. create a new material,
  2. apply the texture to it
  3. edit the prefab and drag the new material onto it.

Super-simple when you realise that a material is a single thing and changing it will change all objects that use that material.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.