The base class of all SpriteKit nodes.
SDKs
- iOS 7.0+
- macOS 10.9+
- Mac Catalyst 13.0+
- tvOS 9.0+
- watchOS 3.0+
Framework
- Sprite
Kit
Declaration
class SKNode : UIResponder
class SKNode : NSResponder
class SKNode : NSObject
Overview
SKNode
provides base properties for its subclasses and it can be used as a container or layout tool for other nodes. For example, you might add a collection of nodes as children to an SKNode
that all move together within the scene; because nodes inherit the properties of their parent, changing the parent node's position
propagates the change to its children as well.
SKNode
does not draw any content itself. Its visual counterparts are listed in Nodes that Draw.