-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbasicjson.go
More file actions
41 lines (35 loc) · 905 Bytes
/
basicjson.go
File metadata and controls
41 lines (35 loc) · 905 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
package main
type Atlas struct {
Meta Meta `json:"meta"`
Frames map[string]Frame `json:"frames"`
}
type Rect struct {
X int `json:"x"`
Y int `json:"y"`
Width int `json:"w"`
Height int `json:"h"`
}
type Point struct {
X float64 `json:"x"`
Y float64 `json:"y"`
}
type Size struct {
Width int `json:"w"`
Height int `json:"h"`
}
type Meta struct {
App string `json:"app"`
Version string `json:"version"`
Image string `json:"image"`
Format string `json:"format"`
Size Size `json:"size"`
}
type Frame struct {
Name string `json:"name"`
Rotated bool `json:"rotated"`
Trimmed bool `json:"trimmed"`
Frame Rect `json:"frame"`
SpriteSourceSize Rect `json:"spriteSourceSize"`
SourceSize Size `json:"sourceSize"`
Pivot Point `json:"pivot"`
}