File tree Expand file tree Collapse file tree 3 files changed +57
-1
lines changed Expand file tree Collapse file tree 3 files changed +57
-1
lines changed Original file line number Diff line number Diff line change
1
+ ## Grid
2
+
3
+ This is an object that defines the grid for a [ tileset] ( tileset.md#tileset ) .
4
+
5
+ ## Grid()
6
+
7
+ ``` lua
8
+ Grid ()
9
+ Grid (otherGrid )
10
+ ```
11
+
12
+ ## Grid.tileSize
13
+
14
+ ``` lua
15
+ local tileSize = grid .tileSize
16
+ ```
17
+
18
+ Returns the [ tile] ( tile.md#tile ) width and height of a [ tileset] ( tileset.md#tileset ) , as a [ size] ( size.md#size ) .
19
+
20
+ ## Grid.origin
21
+
22
+ ``` lua
23
+ local point = grid .origin
24
+ ```
25
+
26
+ Returns the origin of the grid as a [ point] ( point.md#point ) .
Original file line number Diff line number Diff line change 1
1
# Tileset
2
2
3
+ A set of [ tiles] ( tile.md#tile ) .
4
+
3
5
## Tileset.name
4
6
5
- ## Tileset.grid
7
+ ``` lua
8
+ local name = tileset .name
9
+ tileset .name = name
10
+ ```
11
+
12
+ Gets or sets the name of this tileset.
6
13
7
14
## Tileset.baseIndex
8
15
16
+ ``` lua
17
+ local baseindex = tileset .baseIndex
18
+ tileset .baseIndex = baseindex
19
+ ```
20
+
21
+ Gets or sets the base index of this tileset.
22
+
9
23
## Tileset.color
10
24
11
25
## Tileset.data
12
26
27
+ ``` lua
28
+ local data = tileset .data
29
+ tileset .data = data
30
+ ```
31
+
32
+ Gets or sets the user-defined data related to this tileset (a text string).
33
+
13
34
## Tileset.properties
14
35
15
36
Access user-defined and extension-defined
16
37
[ properties] ( properties.md#properties ) of this tileset.
17
38
39
+ ## Tileset.grid
40
+
41
+ ``` lua
42
+ local grid = tileset .grid
43
+ ```
44
+
45
+ Returns the [ grid] ( grid.md#grid ) of this tileset.
46
+
18
47
## Tileset: tile ()
19
48
20
49
``` lua
Original file line number Diff line number Diff line change @@ -39,6 +39,7 @@ Classes/objects
39
39
* [ Events] ( api/events.md#events )
40
40
* [ Frame] ( api/frame.md#frame )
41
41
* [ GraphicsContext] ( api/graphicscontext.md#graphicscontext )
42
+ * [ Grid] ( api/grid.md#grid )
42
43
* [ Image] ( api/image.md#image )
43
44
* [ ImageSpec] ( api/imagespec.md#imagespec )
44
45
* [ KeyEvent] ( api/keyevent.md#keyevent )
You can’t perform that action at this time.
0 commit comments