I need to fill color in a GameObject when somebody hovers over it. How should i go about filling the GameObject with different another color to change the color at once i would use,
Material newMaterial = new Material(Shader.Find("shadername"));
newMaterial.color = whateverColor;
gameObjectRenderer.material = newMaterial ;
but i can’t figure out how to animate color filling.
Example of what i want:
→ Unhovered gameobject will look like
→ Then when somebody hovers over it, the color will start
to fill and a event will be executed when the game-object is filled completely.