Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: wheretheidivides on April 02, 2015, 09:38:05 PM
-
I have a flag waving in the wind using unity 5 (really cool). Under the 'skinned mesh renderer', there is 'materials' and in 'element 0' there is the 'pirat4' graphic. How do I change it to another material?
Using 'set material' I can't find it. I know it's there but not sure what's the crazy name it is given. Thanks
-
Hi,
first you are not using set property properly, you need to drag the component itself, not the gameobject.
Then you have an action "Set Material" that will do just that, have you tried tit already?
Bye,
Jean
-
OK, so you got that right. I was trying to use the game object and not the component. SO now I can change textures.
HOWEVER, my next issue is how do I change it from a prefab? I can change the prefab's texture (the flag) but then the prefab is also change. SO I want to change the texture on a CLONE in the hierarchy.
HOWEVER, the clone is now referenced by a variable. How would I change the texture of the CLONE?
One way is just to change the prefab's texture and then instantiate a object. I could do this every time I create an object. However, is there a better way? I want to be able to change the texture of a clone in the hierarchy that's game object is a variable.