Phaser API Documentation

  Version: 
setSize(width, height, [x], [y])

Description:

Sets the width, height, x and y of this Frame.

This is called automatically by the constructor and should rarely be changed on-the-fly.

Parameters:

name type arguments description
width number

The width of the frame before being trimmed.

height number

The height of the frame before being trimmed.

x number <optional>

The x coordinate of the top-left of this Frame.

y number <optional>

The y coordinate of the top-left of this Frame.

Returns:
Description:

This Frame object.

Since: 3.7.0
Source: src/textures/Frame.js (Line 341)