Class SpriteMap
Hierarchy
- SpriteMap
Implements
Index
Constructors
constructor
Creates a new SpriteMap
Parameters
name: string
defines the SpriteMaps Name
atlasJSON: ISpriteJSONAtlas
is the JSON file that controls the Sprites Frames and Meta
spriteSheet: Texture
is the Texture that the Sprites are on.
options: ISpriteMapOptions
a basic deployment configuration
scene: Scene
The Scene that the map is deployed on
Returns SpriteMap
Properties
atlasJSONSearch playground for atlasJSON
The JSON file with the frame and meta data
nameSearch playground for name
The Name of the spriteMap
optionsSearch playground for options
Arguments passed with the Constructor
sprite SheetSearch playground for spriteSheet
The systems Sprite Sheet Texture
spritesSearch playground for sprites
Public Sprite Storage array, parsed from atlasJSON
Accessors
animation Map
Sets the AnimationMap
Returns RawTexture
Sets the AnimationMap
Parameters
v: RawTexture
Returns void
position
rotation
sprite Count
Returns the Number of Sprites in the System
Returns number
Methods
add Animation To TileSearch playground for addAnimationToTile
Modifies the data of the animationMap
Parameters
Optional cellID: number
is the Index of the Sprite
Optional _frame: number
is the target Animation frame
Optional toCell: number
is the Target Index of the next frame of the animation
Optional time: number
is a value between 0-1 that is the trigger for when the frame should change tiles
Optional speed: number
is a global scalar of the time variable on the map.
Returns void
change TilesSearch playground for changeTiles
disposeSearch playground for dispose
Release associated resources
Returns void
get Mouse PositionSearch playground for getMousePosition
Gets the UV location of the mouse over the SpriteMap.
Returns Vector2
Vector2 the UV position of the mouse interaction
get TileIDSearch playground for getTileID
Returns tileID location
Returns Vector2
Vector2 the cell position ID
load Tile MapsSearch playground for loadTileMaps
Imports the .tilemaps file
Parameters
url: string
of the .tilemaps file
Returns void
save Tile MapsSearch playground for saveTileMaps
Exports the .tilemaps file
Returns void
Class used to manage a grid restricted sprite deployment on an Output plane.