I'm using the Vanila Unity & C# runtimes.
basically, I'm changing the colors by referencing the MeshRenderer and setting the color again for every frame that changes it.
using UnityEngine;
using System.Collections;
public class Changingcolors : MonoBehaviour {
MeshRenderer myRenderer;
void Start () {
myRenderer = GetComponent<MeshRenderer>();
}
// Update is called once per frame
void Update () {
if(change)
{
myRenderer.material.color = new Color (red,green,blue,alpha);
red-=0.01f;
green -= 0.01f;
blue -= 0.01f;
alpha -= 0.01f;
}
}
}
This is a simplified form of it. The funny part is that if I call a different function using an if statement like below:
if (myRenderer.material.color.a <=0)
it will work as intended but the colors won't change if it is not an instanced material.
I am unable to reproduce this in the Spineboy or rather, this code doesn't work to change the colors in the Spineboy scene and the runtime I am using was downloaded last week.
If this is still not enough information, I can pass you my whole project folder through email?