RayCast Delay?

How would I go about scripting a delay for a raycast? Initially how would I change this script so that instead of it shooting the raycast every frame I can change the tempo of it?

    function Update(){
    if (Input.GetButton("Fire1")){
        Shoot();
    }
}

var shotSound: AudioClip; 
var bloodPrefab: GameObject; 
var sparksPrefab: GameObject; 

function Shoot(){
    if (shotSound) audio.PlayOneShot(shotSound); 
    var hit: RaycastHit;
    if (Physics.Raycast(transform.position, transform.forward, hit)){
      
        var rot = Quaternion.FromToRotation(Vector3.up, hit.normal);
        if (hit.transform.tag == "Enemy"){ 
            if (bloodPrefab) Instantiate(bloodPrefab, hit.point, rot); 
            hit.transform.SendMessage("ApplyDamage", 20, SendMessageOptions.DontRequireReceiver); 
        } else { 
            if (sparksPrefab) Instantiate(sparksPrefab, hit.point, rot);
        }
    }
}

You could do something like split the shooting off into a separate Coroutine, which gets fired off from Start()

function ShotPoller()
{
    while(true)
    {
        if(Input.GetButton("Fire1"))
        {
            Shoot();
            yield WaitForSeconds(refireRate);
        } else {
            yield;
        }
    }
}

function Start()
{
    StartCoroutine(ShotPoller());
}

Then just modify ‘refireRate’ until it shoots at the right speed!