Forum Discussion

🚨 This forum is archived and read-only. To submit a forum post, please visit our new Developer Forum. 🚨
jormaje's avatar
jormaje
Explorer
5 years ago

SkinnedMeshRenderer material from OVRHand prefab is overwritten every frame

I want to change the main material from the Skinned Mesh Renderer component (OVRHand prefab).
In Unity Editor this change remains but in build it only remains for 1 frame and it's replaced by the initial material on the next frame.

Is it possible to change hand material in realtime?
Is this a known issue?

1 Reply

  • Ok I found a solution by turning the private variable _originalMaterial from OVRMeshRenderer into a public one.
    It is set on Initialize() and it was being reset every time you are not making the system gesture