title: Detecting if SKAction is done running, Swift
body: <p>I want to change the value of a variable after an action has been run and not during it is running. This is my code:</p>
  
  <pre><code>   override func touchesEnded(touches: Set&lt;NSObject&gt;, withEvent event: UIEvent) {
  
      if gameNotStarted {
          if firePosition.x != 320 || firePosition.y &gt; 280 {  
              fire.runAction(fireButtonReturn)
              iapButton.runAction(iapButtonReturn)
              aboutButton.runAction(abtButtonReturn)
  
              if fire.hasActions() == false {
                  println("has no actions")
                  firePosition.x = 320
                  firePosition.y = 280
              } 
          }       
      }
  }
  </code></pre>
  
  <p>The three actions I am running have exactly the same duration so I only need one to check if they have finished running. After they have finished running I want to change the value of<code>firePosition.x</code> and<code>firePosition.y</code>.
  It is very important that fire position values change exactly after the action has been run and absolutely not before the actions are done running.</p>
  
  <p>However with my current code I never run the<code>if fire.hasActions() ...</code> part according to results and console.
  I found similar questions, they were in obj-c.
  Thanks for your help.</p>