A node that applies physics effects to a portion of the scene.
- iOS 8.0+
- macOS 10.10+
- tvOS 8.0+
- watchOS 2.0+
There are many different kinds of field nodes that can be created, each with different effects. The Creating Field Nodes section lists the field types you can create using Sprite Kit, including a type that allows you to apply custom forces to physics bodies. Instantiate the appropriate kind of field node and then add it to the scene’s node tree.
When the scene simulates physics effects, a field node applies its effect to a physics body so long as the following things are true:
The field node is in the scene’s node tree.
The physics body is attached to a node that is in the scene’s node tree.
The physics body is located inside the field node’s region (see