Instance Method

didChangeSize(_:)

Tells you when the scene’s size has changed.

Declaration

func didChangeSize(_ oldSize: CGSize)

Parameters

oldSize

The old size of the scene, in points.

Discussion

This method is intended to be overridden in a subclass. Typically, you use this method to adjust the positions of nodes in the scene.

See Also

Responding to Loading and Resizing Events

func sceneDidLoad()

Tells you when the scene is presented.

func willMove(from: SKView)

Tells you when the scene is about to be removed from a view.

func didMove(to: SKView)

Tells you when the scene is presented by a view.