title: Optional parameter in class initialization
body: <p>I'm working with Swift, Sprite-Kit and Xcode 6,</p>
  
  <p>I have a class declared like this :</p>
  
  <pre><code>class Obstacles: SKSpriteNode
  {
      init(initTime: Int, speed: CGFloat, positionX: CGFloat, rotationSpeed: CGFloat)
      {
          self.initTime = initTime
          self.rotationSpeed = rotationSpeed
          self.positionX = positionX
  
          super.init(texture: SKTexture(imageNamed: "Rectangle"), color: SKColor.redColor(), size: CGSize(width: 20, height: 20))
          self.speed = speed
      }
  
      var initTime: Int
      var positionX: CGFloat
      var rotationSpeed: CGFloat = 0
  }
  </code></pre>
  
  <p>So I can assign a variable to this class like this :</p>
  
  <pre><code>var myVariable = Obstacles(initTime: 100, speed: 3.0, positionX: 10.0, rotationSpeed: 0.0)
  </code></pre>
  
  <p>but if for example I don't want to initialize the rotationSpeed value and have it default to 0.0, how can I manage to do so ? I can't remove the parameter, it results me an error...</p>