How to randomly apply a material to multiple actors of the same static mesh?

Hi @abc115588,

Here’s an example of how you would set this up in a blueprint:

Keep in mind though that this involves loading all arrayed materials as references for this blueprint. This won’t be a huge deal since you’ll be using all of the references anyways, but just something to keep in mind.

In this example, you create an array of materials, then add indexes for every different material type you might want assigned. When we set the material on the static mesh, we’ll want to read from an index along this array. By getting a random number, every instance of this blueprint should return a different random index. We could set the random int maximum, but why do that when you can find it procedurally? By getting the array length - 1, we get the last index in the array (since array starts on 0)

Good luck! Let me know if you have any more questions.