How can I spawn sprites every 10 degrees around a circle?
<p>I'm very new to coding and would appreciate some help with a small game I'm making to learn.  So I have a circle and I'm trying to create objects at every 10 degree interval around the circle.  I tried this:</p>

<pre><code>override func didMoveToView(view: SKView) {

     self.spawnArrows()

}

func spawnArrows() {

     for var i = 0; i &lt; 36; i++ {

         let arrow = self.createArrow(specificPointOnCircle(Float(self.frame.size.width), center: CGPoint(x: CGRectGetMidX(self.frame), y: CGRectGetMidY(self.frame)), angle: Float(i * 10)))
         self.addChild(arrow)

     }
}

func specificPointOnCircle(radius:Float, center:CGPoint, angle:Float) -&gt; CGPoint {

    let theta = angle * Float(M_PI) + 2.0
    let x = radius * cosf(theta)
    let y = radius * sinf(theta)
    return CGPoint(x: CGFloat(x) + center.x, y: CGFloat(y) + center.y)

}

func createArrow(position: CGPoint) -&gt; SKSpriteNode {

    let arrow = SKSpriteNode(imageNamed: "Arrow.png")
    arrow.zPosition = 2
    arrow.size = CGSize(width: self.frame.size.width * 0.12, height: self.frame.size.width * 0.025)
    arrow.position = position
    return arrow

}
</code></pre>

<p>But nothing at all is showing up.  Is my math wrong somewhere, or my syntax, or perhaps both?  Any help is appreciated.</p>