Type Method

scaleToSize:duration:

Creates an action that changes the x and y scale values of a node to achieve

Declaration

+ (SKAction *)scaleToSize:(CGSize)size duration:(NSTimeInterval)duration;

Parameters

size

The new size of the node.

sec

The duration of the animation.

Return Value

A new action object.

Discussion

When the action executes, the node’s xScale and yScale properties are animated to achieve the specified size in its parent's coordinate space.

This action is not reversible; the reverse of this action has the same duration but does not change anything.

See Also

Animating the Scaling of a Node

+ scaleBy:duration:

Creates an action that changes the x and y scale values of a node by a relative value.

+ scaleTo:duration:

Creates an action that changes the x and y scale values of a node.

+ scaleXBy:y:duration:

Creates an action that adds relative values to the x and y scale values of a node.

+ scaleXTo:y:duration:

Creates an action that changes the x and y scale values of a node.

+ scaleXTo:duration:

Creates an action that changes the x scale value of a node to a new value.

+ scaleYTo:duration:

Creates an action that changes the y scale value of a node to a new value.