presentScene(_:transition:)
Transitions from the current scene to a new scene.
Declaration
func presentScene(_ scene: SKScene, transition: SKTransition)Parameters
- scene:
The scene to present.
- transition:
A transition used to animate between the two scenes.
Discussion
If there is currently a scene presented by the view, the view’s scene property is updated immediately, the transition is executed to swap between the scenes. Otherwise, the new scene is presented immediately and the transition property is ignored.