run(_:completion:)
Adds an action to the list of actions executed by the node and schedules the argument block to be run upon completion of the action.
Declaration
func run(_ action: SKAction, completion block: @escaping () -> Void)func run(_ action: SKAction) asyncfunc run(_ action: SKAction, completion block: @escaping @Sendable () -> Void)Parameters
- action:
The action to perform.
- block:
A completion block called when the action completes.