Material SubUV_Function Random Starting Frame?

You could do something based on object position, like this:

350046-rand.gif

Hi,
I’m using a Material SubUV_Function to animate a material. But since I have many objects using that material I want each instance to have a random starting frame so as they loop they are not all in sequence. How can I do this. I’m not married to SubUV_Function, so it doesn’t have to be that method.

Are the objects moving?

An easier way to do it, would be to pass the current frame you want played from blueprint to a material instance on the object.

I definitely can, my problem is that if I want to use that I can’t have linear animation.

I tried to use position to add a random number to the frame, but I couldn’t quite get it to work. any ideas?

it is moving. how would I pass the frame to the mat?

Here’s the quick answer, because I don’t have much time now.

Put the mesh in a blueprint, assign a dynamic material instance, choose your random start frame on begin play and change frames on a timer.

Just come back to me if that’s not enough ( or I’ve missed something ), and I’ll drop some code tomorrow…