Hello everyone,
Im trying to get a effect which consist of getting a pulsing glow on a object which has to get picked up in the game so the player can see it easyer.
I tried to animate the main color of the self illum shader but I could figure it out.
Something similar but it doesnt need to be on the edge
// Interpolate light color between two colors back and forth
var duration : float = 1.0;
var color0 : Color = Color.red;
var color1 : Color = Color.blue;
function Update () {
// set light color
var t : float = Mathf.PingPong (Time.time, duration) / duration;
light.color = Color.Lerp (color0, color1, t);
}
I found this for a lamp tried to adap it but i failed…
I hope you guys can help me out
Greetings
Saudius