title: Game freezes for a second when player fires projectile in Sprite-kit
body: <p>Game freezes for a second when the player fires the first bullet.</p>
  
  <p>I'm trying to create a space shooter in Xcode. This is code I'm using to move the bullet once the player taps the screen.</p>
  
  <pre><code> func fireLaser() {
  
      if(!canFire) {
          return
      } else {
  
          canFire = false
  
          let laserSound = SKAction.playSoundFileNamed("Shot 4.mp3", waitForCompletion: false)
          run(laserSound)
  
          laser = Projectile(imageNamed: "Laser_Medium")
          laser.name = "projectileName"
          laser.initalize()
          laser.position = player.position
          laser.position.y += 70
          laser.setScale(0.9)
          addChild(laser)
  
          let moveUp = SKAction.move(to: CGPoint(x: player.position.x, y: 850), duration: 1)
          laser.run(moveUp)
  
          let waitToEnableFire = SKAction.wait(forDuration: 0.75)
          run(waitToEnableFire,completion:{self.canFire = true})
      }
  
  }
  </code></pre>
  
  <p>The bullet is spawning and moving but freezes the game for a second the first time the bullet is fired.</p>