playMaker

Author Topic: Find objects which share same material  (Read 467 times)

emildragan

  • Playmaker Newbie
  • *
  • Posts: 28
Find objects which share same material
« on: November 03, 2021, 02:47:26 PM »
Hello,

I need to find all the gamobjects in the scene that share the same material, the material name I have it saved into a string variable. I see that here is an older thread regarding FindObjectbyType, but you need to manually asssign UNity.Enigne....., something like so.
First I need to know if is there an action called FindObjects, not Object and what should I assign in that string in order to find all the objects which share a specific material.

Thank you.

heavygunner

  • Sr. Member
  • ****
  • Posts: 344
Re: Find objects which share same material
« Reply #1 on: November 04, 2021, 10:58:45 AM »
set different tag to the objects that use specific material.
download Array maker from eco system and add those objects into array