How to wait in a update function?

How would I make a yield, or anything that waits for about the amount of time that it takes to shoot a bullet from a machine gun, (say around .2 or .1) and I cant seem to find anything that does this, because you can use yields in an update.
Here the code, any suggestions?

#pragma strict

var c1 : Color = Color.yellow;
var c2 : Color = Color.red;
var lineRenderer : LineRenderer;
var myPrefab = gameObject;
//var projectile = gameObject;
function Start() {
     lineRenderer = gameObject.AddComponent(LineRenderer);
     lineRenderer.material = new Material (Shader.Find("Particles/Additive"));
     lineRenderer.SetColors(c1, c2);
     lineRenderer.SetWidth(0.2,0.2);
     lineRenderer.SetVertexCount(2);
}

function Update(){
var origin = transform.position;
var direction = transform.forward;
var endPoint = origin + direction * 100000;
var hit : RaycastHit;

lineRenderer.SetPosition(0, origin);
     if (Input.GetButton/*Down*/("Fire1") Time.deltaTime * 5) {
       framesToSkip = 50;
 //    var clone = Instantiate(projectile, transform.position, transform.rotation) as Rigidbody;


   //clone.AddForce(0,2000,0); 

     //while(Input.GetButtonDown("Fire1")){
if (Physics.Raycast(origin,direction,hit))
Instantiate(myPrefab, hit.point, Quaternion.identity);
endPoint = hit.point;

lineRenderer.SetPosition(1, endPoint);

}

}

var timer : float;
var timeToWait : float = 0.2;

void Update{

timer += Time.deltaTime;
if(timer > timeToWait)
{
doStuff
timer = 0;
}

}

thats how i generally do it, simple as it is, i think thats the right js? i usually use c#

Nevermind, works great. Just a few simple errors because some of its in C#, but otherwise thanks a lot. 5 hours gained, thanks.

no, you put the two vars under #pragma strict, and the if bit in your update function, you put whatever you want to happen after the wait where do stuff is

well whatever it is, its working. So I don’t really want to mess with it.

Also another random question, How do I distroy a clone?

This doesn’t seem to be working, Destroy(GameObject.Find(“bulletmark(Clone)”), 5);

Keep a reference to the object you want to destroy. Not only is Find abysmally slow, but if you have two objects with the same name (nearly always the case with clones), it’ll choose one “at random”.