Speed Pick Up script

I need a simple script that ups the players movement speed times 2 for a set amount of seconds. Here is what i got. Also I am attaching this to a simple sphere and setting it as a trigger.

var speedUpTime : float = 5; // How long do you have a speed boost

var speedUpFactor : float = 1;

var controller : CharacterController; 





function OnTriggerEnter(hit : Collider){

//		//Did we hit the object

	if (hit.gameObject.tag == "Player"){

 //  		//get the speed var from character motor script

     CharacterMotor.Speed = 15;



	}

}

So what’s the problem? Is it working differently from what you’re expecting? Where’s CharacterMotor coming from?

No it is not working at all. I am using the default first person character controller. I attached the script to the sphere object that has a trigger. When I pass through the sphere nothing happens. The speed does not increase at all. Is there another way I could do this. I am at Game Jam and really need help ASAP, it is key to our game.

anyone