title: How to loop through point in UIBezierPath swift?
body: <p>How can I loop through the circle UIBezierPath coordinates so I can move the dot object over the circular path when the user moves their finger on the screen? (kind of like a virtual combination lock)</p>
  
  <pre><code>let blueDotCategoryName = "blue"
  var blueDot = SKSpriteNode()
  
  //...    
  
  override func touchesBegan(touches: NSSet, withEvent event: UIEvent) {
      /* Called when a touch begins */
      let touch = touches.anyObject() as UITouch
      let touchLocation = touch.locationInNode(self)
      let node = self.nodeAtPoint(touchLocation)
      if node.name == blueDotCategoryName {
          fingerIsOn = true
      }
  }
  
  
  
  override func touchesMoved(touches: NSSet, withEvent event: UIEvent) {
      if fingerIsOn {
          let touch = touches.anyObject() as UITouch
          let touchLocation = touch.locationInNode(self)
          let prevTouchLocation = touch.previousLocationInNode(self)
          let blueDot = self.childNodeWithName(blueDotCategoryName) as SKSpriteNode
         // var newPosition = coordinates in circle UIBezierPath
         // blueDot.position = ...
      }
  /*        
      var circle = UIBezierPath()
      circle.addArcWithCenter(CGPoint(x: 0, y: 0), radius: (self.frame.width / 6.7), startAngle: 0, endAngle: 360, clockwise: true)       
  */
  
  }
  override func touchesEnded(touches: NSSet, withEvent event: UIEvent) {
    fingerIsOn = false
  }
  </code></pre>