Then create a material with that shader and assign the mat to sprite render, finally in script:

sRender.material.SetColor("_Color",Color.black);// the bottom colorsRender.material.SetColor("_Color2",Color.white);// the top color

Transition

privatefloatduration=1.0f;publicSpriteRenderersRender;// Update is called once per frameColorHexToColor(stringhex){byter=byte.Parse(hex.Substring(0,2),System.Globalization.NumberStyles.HexNumber);byteg=byte.Parse(hex.Substring(2,2),System.Globalization.NumberStyles.HexNumber);byteb=byte.Parse(hex.Substring(4,2),System.Globalization.NumberStyles.HexNumber);returnnewColor32(r,g,b,255);}voidUpdate(){floatlerp=Mathf.PingPong(Time.time,duration)/duration;sRender.material.SetColor("_Color",Color.Lerp(HexToColor("fe805e"),HexToColor("fa8856"),lerp));//bottomsRender.material.SetColor("_Color2",Color.Lerp(HexToColor("527fc1"),HexToColor("7ae0ec"),lerp));//top}