Swift NSTimer retrieving userInfo as CGPoint
问题 override func touchesBegan(touches: NSSet, withEvent event: UIEvent) { let touch = touches.anyObject() as UITouch let touchLocation = touch.locationInNode(self) timer = NSTimer.scheduledTimerWithTimeInterval(0.5, target: self, selector: "shoot", userInfo: touchLocation, repeats: true) // error 1 } func shoot() { var touchLocation: CGPoint = timer.userInfo // error 2 println("running") } I am trying to create a timer that runs periodicly that passes the touched point (CGPoint) as userInfo to