0
\$\begingroup\$

What are the difference between Renderer.sharedMaterial and Renderer.sharedMaterials in Unity?

\$\endgroup\$

1 Answer 1

2
\$\begingroup\$

Renderer.sharedMaterial returns first material used by a Renderer or null if Renderer has no materials. If there`re multiple materials, first one in that array will be returned.

Renderer.sharedMaterials returns all (1, 2, ...) materials used by a Renderer as array or null if Renderer has no materials.

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .