Difference between revisions of "TileMap:setTexture"
From GiderosMobile
Line 1: | Line 1: | ||
__NOTOC__ | __NOTOC__ | ||
'''<translate>Available since</translate>:''' Gideros 2018.2<br/> | '''<translate>Available since</translate>:''' Gideros 2018.2<br/> | ||
+ | '''<translate>Class</translate>:''' [[Special:MyLanguage/TileMap|TileMap]]<br/> | ||
=== <translate>Description</translate> === | === <translate>Description</translate> === | ||
<translate><br /> | <translate><br /> |
Revision as of 09:27, 24 August 2018
Available since: Gideros 2018.2
Class: TileMap
Description
Change the tile texture/atlas used by the tilemap.
TileMap:setTexture(texture,tilewidth,tileheight,spacingx,spacingy,marginx,marginy)
Parameters
texture: (TextureBase) The texture used in rendering tile map
tilewidth: (number) The width of a tile in pixels
tileheight: (number) The height of a tile in pixels
spacingx: (number, default = 0) The x-spacing in pixels between the tiles in this tileset
spacingy: (number, default = 0) The y-spacing in pixels between the tiles in this tileset
marginx: (number, default = 0) The x-margin from the top-left of the texture
marginy: (number, default = 0) The y-margin from the top-left of the texture