2016-01-19 23:21:15.132 Test2 [86049:25427867] ***由於未捕獲異常'NSInvalidArgumentException',原因:'Receiver()沒有標識符'gameSegue'正在執行準備工作
override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
if segue.identifier == "gameSegue"{
let gameViewController = segue.destinationViewController as! GameViewController
gameViewController.performSegueWithIdentifier("gameSegue", sender: gameViewController)
}
}
viewController = MainMenuViewController()
let segue = UIStoryboardSegue(identifier: "gameSegue", source: MainMenuViewController(), destination: GameViewController())
viewController.prepareForSegue(segue, sender: self)
我得到上面每當我打電話prepareForSegue功能
檢查[這些搜索結果](http://stackoverflow.com/search?q=%22has+no+segue+with+identifier%22+NSInvalidArgumentException+%5Bswift%5D)。 – rmaddy