When to use didMoveToView or initWithSize with SpriteKit in xCode 6.4

后端 未结 3 1930
失恋的感觉
失恋的感觉 2021-01-03 03:39

Since xCode was updated to version 6.0, the default method for SpriteKit in \"GameScene\" (the default scene created) changes to:

-(void) didMoveToView:(SKVi         


        
3条回答
  •  鱼传尺愫
    2021-01-03 03:59

    Both options are correct. Said that, the init method is not actually the same than the didMoveToView: method, as this last one will be called once the SKScene is presented in a SKView.

提交回复
热议问题