Dual Timer Problems

Hello,

I have a script that I am working on that has a counter to enable an object however I can’t find a way to make it object specific. As soon as the awake function is called the timer starts and I tried to connect it to and empty that connected to a timer as well a timer script as well but it won’t disable object and shows no errors. My goal is to have perks that can be deactivated on touch and self timer reactivates it.

Here is the Script timer I am trying to create to work for individual object and children:

var perk1 : GameObject;

var perktimer1 : int;


function Awake (){
 		  perk1.active = false;
                
             }
function Update () {

		perktimer1++;
     guiText.text = "Grow time: "+perktimer1;

 			if (perktimer1 > 400){ 	
 				perk1.active = true;
        		
 	}
			
 }

I’d add the script to the Perk object itself and then use invoke ( http://unity3d.com/support/documentation/ScriptReference/MonoBehaviour.Invoke ) for the reactivation. So something like this:

var isActive:bool

function Start()
{
    isActive = true;
}

function UsePerk()
{
    //do stuff
    isActive = false;
    Invoke("Reactivate", 10); // call the function Reactivate after 10 seconds
}

function Reactivate()
{
    isActive = true;
}