The path that defines the shape.
SDKs
- iOS 7.0+
- macOS 10.9+
- Mac Catalyst 13.0+
- tvOS 9.0+
- watchOS 3.0+
Framework
- Sprite
Kit
Declaration
var path: CGPath? { get set }
Discussion
The path is defined in the node’s coordinate space.
The path that defines the shape.
SDKs
Framework
var path: CGPath? { get set }
The path is defined in the node’s coordinate space.
init(path: CGPath)
Creates a shape node from a Core Graphics path.
init(path: CGPath, centered: Bool)
Creates a shape node from a Core Graphics path, centered around its position.