0
我需要創建一個從屏幕中間以小半徑開始的圓,它從中心逐漸增大。如果圈子是SKSpriteNode
,有什麼辦法可以做到這一點?想法是爲了增加半徑,沒有其他品質如中風增加。如何在Swift中更改SKSpriteNode的半徑?
到目前爲止:
func randomCircle(){
let RandomCircleShape = SKShapeNode(circleOfRadius: 1)
RandomCircleShape.position = CGPoint(x: CGRectGetMidX(self.frame), y: CGRectGetMidY(self.frame))
RandomCircleShape.strokeColor = randomColor()
RandomCircleShape.lineWidth = 2
self.addChild(RandomCircleShape)
}