Each time I fire a projectile, it doubles it (Mobile)

So I have a script i use for shooting a default sphere in my scene. Each time I press on the screen, I want it to shoot one bullet, then take maybe 1-2 seconds before it will be able to fire again. But each time I fire it, the bullets just double and if you keep on pressing the screen/button, it starts to lag and no mobile device could handle it. Here is the script:

 #pragma strict

 public var projectile : Rigidbody;
  public var shotPos : Transform;
  public var shotForce : float = 1000f;
  public var moveSpeed : float = 10f;

  function Update ()
 {
var h : float = Input.GetAxis("Horizontal") * Time.deltaTime * moveSpeed;
var v : float = Input.GetAxis("Vertical") * Time.deltaTime * moveSpeed;

transform.Translate(new Vector3(h, v, 0f));

if(Input.GetButtonUp("Fire1"))
{
    var shot : Rigidbody = Instantiate(projectile, shotPos.position, shotPos.rotation);
    shot.AddForce(shotPos.forward * shotForce);
   }
 }

Thanks!

The problem that i can see is that it should be GetButtonDown(“Fire1”) first of all. This will fire the bullet everytime you touch/click. If you want something like a reload, then you need to implement a time mechanism.

The lag that’s coming is probably because you are not destroying the bullets. The best way to do that is destroy them after like 2-3 secs or when they are out of range or something. A destroy mechanism is very essential for shooting games because otherwise you have too many gameobjects in your game to render and that takes up all the processing and your game will start lagging and will eventually hang.