defineSpriteSheet
Call Signature
Section titled “Call Signature”defineSpriteSheet<
Clip>(options):SpriteSheet<Clip>
Declares a sprite sheet at module scope: one image with Aseprite’s or
TexturePacker’s JSON, or one image cut into a grid. Every clip it holds
plays through playClip and a Sprite’s clip. The data is checked
here, throwing naming the file and the frame, and the image is checked
against it when it loads.
Type Parameters
Section titled “Type Parameters”| Type Parameter |
|---|
Clip extends string |
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
options |
SpriteSheetDataOptions<Clip> & object |
Returns
Section titled “Returns”SpriteSheet<Clip>
Call Signature
Section titled “Call Signature”defineSpriteSheet(
options):SpriteSheet<string>
Declares a sprite sheet at module scope: one image with Aseprite’s or
TexturePacker’s JSON, or one image cut into a grid. Every clip it holds
plays through playClip and a Sprite’s clip. The data is checked
here, throwing naming the file and the frame, and the image is checked
against it when it loads.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
options |
SpriteSheetDataOptions<string> |
Returns
Section titled “Returns”SpriteSheet<string>
Call Signature
Section titled “Call Signature”defineSpriteSheet<
Clip>(options):SpriteSheet<Clip>
Declares a sprite sheet at module scope: one image with Aseprite’s or
TexturePacker’s JSON, or one image cut into a grid. Every clip it holds
plays through playClip and a Sprite’s clip. The data is checked
here, throwing naming the file and the frame, and the image is checked
against it when it loads.
Type Parameters
Section titled “Type Parameters”| Type Parameter |
|---|
Clip extends string |
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
options |
SpriteSheetGridOptions<Clip> & object |
Returns
Section titled “Returns”SpriteSheet<Clip>
Call Signature
Section titled “Call Signature”defineSpriteSheet(
options):SpriteSheet<"all">
Declares a sprite sheet at module scope: one image with Aseprite’s or
TexturePacker’s JSON, or one image cut into a grid. Every clip it holds
plays through playClip and a Sprite’s clip. The data is checked
here, throwing naming the file and the frame, and the image is checked
against it when it loads.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
options |
SpriteSheetGridOptions<string> & object |
Returns
Section titled “Returns”SpriteSheet<"all">