sprite_sheet
the methods for the sprite_sheet object
make_animation(collumn, duration) | creates an animated texture object from this sprite sheet |
---|---|
get(sprite_sheet_x, sprite_sheet_y) | returns a specific texture saved in the sprite sheet. |
fields | the fields stored in the sprite_sheet object |
- make_animation(collumn, duration)Source
creates an animated texture object from this sprite sheet
Parameters
- collumn number collumn the animated texture should use for the animation
- duration number duration of the animation
Returns
- animated_texture an animated texture object
- get(sprite_sheet_x, sprite_sheet_y)Source
returns a specific texture saved in the sprite sheet.
Parameters
- sprite_sheet_x number
x
position of the texture in the sprite sheet - sprite_sheet_y number
y
position of the texture in the sprite sheet
Returns
- texture a texture object
- sprite_sheet_x number
- fieldsSource
the fields stored in the sprite_sheet object
sprites a 2D map of all the textures saved in the sprite sheet sprite_width the width of individual sprites in pixels sprite_height the height of individual sprites in pixels sprites_x the amount of sprites saved in the sprite sheet in the x
sprites_y the amount of sprites saved in the sprite sheet in the y
- spritesSource
a 2D map of all the textures saved in the sprite sheet
- sprite_widthSource
the width of individual sprites in pixels
- sprite_heightSource
the height of individual sprites in pixels
- sprites_xSource
the amount of sprites saved in the sprite sheet in the
x
- sprites_ySource
the amount of sprites saved in the sprite sheet in the
y