+1 vote

When you duplicate a MeshInstance, the Material and Mesh will refer to the same ones from the original MeshInstance.
I know that if I want to play with the Material separately, I can make it unique.
But, you can make them unique, but it's hard to make dozens of objects unique one by one.

Is there any way to make them unique at the same time as duplicating them?
Or, is there a way to make all objects unique at once?

Godot version 3.4
in Engine by (25 points)

You duplicate in editor (like ctrl+D) or in code ?

Have you tried overriding the material on the mesh? There's a way to do it, but the method currently escapes me.

In editor. ctrl+D.

I also tried Material override. The result was the same.

1 Answer

+1 vote

You can go to Resource property of original mesh and material and set localtothe_scene as true. But if I recall correctly, there is a problem with duplicate itself, and it might still not work.

by (7,447 points)

Still the result is the same, I don't even know what the Local to scene property is for.

It works if scene is instanced from code, it makes every new instance automatically to "makeunique". As I suspected, this does not work with duplicating, both in code and in editor. I am afraid You have to duplicate naked mesh scene without material and set it after. Or You can create a scene from meshinstance with material and make "newinherited_scene" from it. It should work better than duplicate.

Excuse me, but what does it mean to create a scene from meshInstance? What does "newinherited_scene" mean?
I'm not very good at English, so I don't know what you're talking about...

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.