TileMap.new: Difference between revisions
Created page with "__NOTOC__ '''Available since:''' Gideros 2011.6<br/> === Description === <br /> Creates a new `TileMap` instance.<br /> <br /> <source lang="lua"> = TileMap.new(widthheighttex..." |
No edit summary |
||
| Line 6: | Line 6: | ||
<br /> | <br /> | ||
<source lang="lua"> | <source lang="lua"> | ||
TileMap.new(width,height,texture,tilewidth,tileheight,spacingx,spacingy,marginx,marginy,displaywidth,displayheight) | |||
</source> | </source> | ||
'''width | '''width''': (number) The width of the map in tiles ''''''<br/> | ||
'''height | '''height''': (number) The height of the map in tiles ''''''<br/> | ||
'''texture | '''texture''': (TextureBase) The texture used in rendering tile map ''''''<br/> | ||
'''tilewidth | '''tilewidth''': (number) The width of a tile in pixels ''''''<br/> | ||
'''tileheight | '''tileheight''': (number) The height of a tile in pixels ''''''<br/> | ||
'''spacingx | '''spacingx''': (number, default = 0) The x-spacing in pixels between the tiles in this tileset ''''''<br/> | ||
'''spacingy | '''spacingy''': (number, default = 0) The y-spacing in pixels between the tiles in this tileset ''''''<br/> | ||
'''marginx | '''marginx''': (number, default = 0) The x-margin from the top-left of the texture ''''''<br/> | ||
'''marginy | '''marginy''': (number, default = 0) The y-margin from the top-left of the texture ''''''<br/> | ||
'''displaywidth | '''displaywidth''': (number, default = tilewidth) The display width of a tile in pixels ''''''<br/> | ||
'''displayheight | '''displayheight''': (number, default = tileheight) The display height of a tile in pixels ''''''<br/> | ||
Revision as of 09:20, 23 August 2018
Available since: Gideros 2011.6
Description
Creates a new `TileMap` instance.
TileMap.new(width,height,texture,tilewidth,tileheight,spacingx,spacingy,marginx,marginy,displaywidth,displayheight)
'width: (number) The width of the map in tiles '
'height: (number) The height of the map in tiles '
'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 '
'displaywidth: (number, default = tilewidth) The display width of a tile in pixels '
'displayheight: (number, default = tileheight) The display height of a tile in pixels '