Contents

falloff(to:duration:)

Creates an action that animates a change of a physics field’s falloff.

Declaration

class func falloff(to falloff: Float, duration: TimeInterval) -> SKAction

Parameters

  • falloff:

    The new falloff for the field.

  • duration:

    The duration of the animation, in seconds.

Return Value

A new action object.

Discussion

When the action runs, the field node’s falloff property animates from its current value to its new value. This action is not reversible.

See Also

Animating Properties of a Node’s Physics Body