Where is the right place to configure SKScene content in SpriteKit?
问题 Is it ok to configure (position sprites, add visible nodes etc) an SKScene's content in init method? Where is the right place for such things: init? didMoveToView? something else? 回答1: didMoveToView: is called every time the scene is presented by an SKView. Pros of positioning and adding sprites in didMoveToView: You can initialise many views without them grabbing a lot of memory. Cons: If you remove a view and then add it again didMoveToView: is called again. This means that you need to be