light intensity change with easing problem!!

hi i have this script named light control.js

var sun : GameObject;
var lightchange: float = 0.1;
var lightnormal: float = 0.7;
function OnTriggerEnter() {
    sun.light.intensity = lightchange;
function OnTriggerExit() {
    sun.light.intensity = lightnormal;

now as you can see i have a collider trigger to decrease the intensity of sun(directional light). but the problem is the intensity changed quickly without any easing effect…

i searched a lot to how to easing the changing between them but cant actually add them to my script to make it working… :frowning:
Tell me how to do the easing thing and how to add that…

The best way is to create a quick animation which animates the light intensity.