@skyblock-finance/actions 0.4.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/data/$schema.json +162 -83
- package/data/gems.json +10 -10
- package/data/skymart.json +984 -0
- package/dist/.tsbuildinfo +1 -1
- package/dist/data.d.ts +11 -10
- package/dist/data.js +4 -1
- package/dist/schema.d.ts +138 -337
- package/dist/schema.js +42 -27
- package/dist/types.d.ts +1 -1
- package/package.json +5 -4
- package/source/data.test.ts +1 -1
- package/source/data.ts +4 -0
- package/source/schema.ts +21 -5
- package/source/types.ts +1 -1
package/data/$schema.json
CHANGED
|
@@ -1,40 +1,6 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://json-schema.org/draft-
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
3
|
"additionalProperties": false,
|
|
4
|
-
"definitions": {
|
|
5
|
-
"currencyAction": {
|
|
6
|
-
"additionalProperties": false,
|
|
7
|
-
"properties": {
|
|
8
|
-
"amount": {
|
|
9
|
-
"type": "number"
|
|
10
|
-
},
|
|
11
|
-
"id": {
|
|
12
|
-
"enum": ["bit", "coin", "gem", "mote", "north-star", "pest", "usd"],
|
|
13
|
-
"type": "string"
|
|
14
|
-
},
|
|
15
|
-
"type": {
|
|
16
|
-
"const": "currency"
|
|
17
|
-
}
|
|
18
|
-
},
|
|
19
|
-
"required": ["amount", "id", "type"]
|
|
20
|
-
},
|
|
21
|
-
"itemAction": {
|
|
22
|
-
"additionalProperties": false,
|
|
23
|
-
"properties": {
|
|
24
|
-
"amount": {
|
|
25
|
-
"type": "number"
|
|
26
|
-
},
|
|
27
|
-
"id": {
|
|
28
|
-
"type": "string"
|
|
29
|
-
},
|
|
30
|
-
"type": {
|
|
31
|
-
"const": "item"
|
|
32
|
-
}
|
|
33
|
-
},
|
|
34
|
-
"required": ["id", "amount", "type"],
|
|
35
|
-
"type": "object"
|
|
36
|
-
}
|
|
37
|
-
},
|
|
38
4
|
"properties": {
|
|
39
5
|
"$schema": {
|
|
40
6
|
"type": "string"
|
|
@@ -45,38 +11,152 @@
|
|
|
45
11
|
"properties": {
|
|
46
12
|
"inputs": {
|
|
47
13
|
"items": {
|
|
48
|
-
"
|
|
49
|
-
{
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
14
|
+
"anyOf": [
|
|
15
|
+
{
|
|
16
|
+
"additionalProperties": false,
|
|
17
|
+
"properties": {
|
|
18
|
+
"amount": {
|
|
19
|
+
"type": "number"
|
|
20
|
+
},
|
|
21
|
+
"id": {
|
|
22
|
+
"enum": [
|
|
23
|
+
"bit",
|
|
24
|
+
"coin",
|
|
25
|
+
"copper",
|
|
26
|
+
"gem",
|
|
27
|
+
"north-star",
|
|
28
|
+
"pest",
|
|
29
|
+
"second",
|
|
30
|
+
"usd"
|
|
31
|
+
],
|
|
32
|
+
"type": "string"
|
|
33
|
+
},
|
|
34
|
+
"type": {
|
|
35
|
+
"const": "currency",
|
|
36
|
+
"type": "string"
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
"required": ["amount", "id", "type"],
|
|
40
|
+
"type": "object"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"additionalProperties": false,
|
|
44
|
+
"properties": {
|
|
45
|
+
"amount": {
|
|
46
|
+
"type": "number"
|
|
47
|
+
},
|
|
48
|
+
"id": {
|
|
49
|
+
"type": "string"
|
|
50
|
+
},
|
|
51
|
+
"type": {
|
|
52
|
+
"const": "item",
|
|
53
|
+
"type": "string"
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
"required": ["amount", "id", "type"],
|
|
57
|
+
"type": "object"
|
|
58
|
+
}
|
|
59
|
+
]
|
|
53
60
|
},
|
|
54
61
|
"type": "array"
|
|
55
62
|
},
|
|
56
63
|
"outputs": {
|
|
57
64
|
"items": {
|
|
58
|
-
"
|
|
59
|
-
{
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
65
|
+
"anyOf": [
|
|
66
|
+
{
|
|
67
|
+
"additionalProperties": false,
|
|
68
|
+
"properties": {
|
|
69
|
+
"amount": {
|
|
70
|
+
"type": "number"
|
|
71
|
+
},
|
|
72
|
+
"id": {
|
|
73
|
+
"enum": [
|
|
74
|
+
"bit",
|
|
75
|
+
"coin",
|
|
76
|
+
"copper",
|
|
77
|
+
"gem",
|
|
78
|
+
"north-star",
|
|
79
|
+
"pest",
|
|
80
|
+
"second",
|
|
81
|
+
"usd"
|
|
82
|
+
],
|
|
83
|
+
"type": "string"
|
|
84
|
+
},
|
|
85
|
+
"type": {
|
|
86
|
+
"const": "currency",
|
|
87
|
+
"type": "string"
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
"required": ["amount", "id", "type"],
|
|
91
|
+
"type": "object"
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"additionalProperties": false,
|
|
95
|
+
"properties": {
|
|
96
|
+
"amount": {
|
|
97
|
+
"type": "number"
|
|
98
|
+
},
|
|
99
|
+
"id": {
|
|
100
|
+
"type": "string"
|
|
101
|
+
},
|
|
102
|
+
"type": {
|
|
103
|
+
"const": "item",
|
|
104
|
+
"type": "string"
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
"required": ["amount", "id", "type"],
|
|
108
|
+
"type": "object"
|
|
109
|
+
}
|
|
110
|
+
]
|
|
63
111
|
},
|
|
64
112
|
"type": "array"
|
|
65
113
|
},
|
|
66
114
|
"place": {
|
|
67
115
|
"items": {
|
|
68
|
-
"
|
|
116
|
+
"anyOf": [
|
|
69
117
|
{
|
|
70
118
|
"additionalProperties": false,
|
|
71
119
|
"properties": {
|
|
72
|
-
"
|
|
73
|
-
"
|
|
120
|
+
"left": {
|
|
121
|
+
"additionalProperties": false,
|
|
122
|
+
"properties": {
|
|
123
|
+
"amount": {
|
|
124
|
+
"type": "number"
|
|
125
|
+
},
|
|
126
|
+
"id": {
|
|
127
|
+
"type": "string"
|
|
128
|
+
},
|
|
129
|
+
"type": {
|
|
130
|
+
"const": "item",
|
|
131
|
+
"type": "string"
|
|
132
|
+
}
|
|
133
|
+
},
|
|
134
|
+
"required": ["amount", "id", "type"],
|
|
135
|
+
"type": "object"
|
|
136
|
+
},
|
|
137
|
+
"right": {
|
|
138
|
+
"additionalProperties": false,
|
|
139
|
+
"properties": {
|
|
140
|
+
"amount": {
|
|
141
|
+
"type": "number"
|
|
142
|
+
},
|
|
143
|
+
"id": {
|
|
144
|
+
"type": "string"
|
|
145
|
+
},
|
|
146
|
+
"type": {
|
|
147
|
+
"const": "item",
|
|
148
|
+
"type": "string"
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
"required": ["amount", "id", "type"],
|
|
152
|
+
"type": "object"
|
|
74
153
|
},
|
|
75
154
|
"type": {
|
|
76
|
-
"const": "
|
|
155
|
+
"const": "anvil",
|
|
156
|
+
"type": "string"
|
|
77
157
|
}
|
|
78
158
|
},
|
|
79
|
-
"required": ["
|
|
159
|
+
"required": ["left", "right", "type"],
|
|
80
160
|
"type": "object"
|
|
81
161
|
},
|
|
82
162
|
{
|
|
@@ -86,7 +166,8 @@
|
|
|
86
166
|
"type": "string"
|
|
87
167
|
},
|
|
88
168
|
"type": {
|
|
89
|
-
"const": "npc"
|
|
169
|
+
"const": "npc",
|
|
170
|
+
"type": "string"
|
|
90
171
|
}
|
|
91
172
|
},
|
|
92
173
|
"required": ["id", "type"],
|
|
@@ -96,9 +177,11 @@
|
|
|
96
177
|
"additionalProperties": false,
|
|
97
178
|
"properties": {
|
|
98
179
|
"type": {
|
|
99
|
-
"const": "website"
|
|
180
|
+
"const": "website",
|
|
181
|
+
"type": "string"
|
|
100
182
|
},
|
|
101
183
|
"url": {
|
|
184
|
+
"format": "uri",
|
|
102
185
|
"type": "string"
|
|
103
186
|
}
|
|
104
187
|
},
|
|
@@ -110,48 +193,44 @@
|
|
|
110
193
|
"properties": {
|
|
111
194
|
"grid": {
|
|
112
195
|
"items": {
|
|
113
|
-
"
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
196
|
+
"anyOf": [
|
|
197
|
+
{
|
|
198
|
+
"additionalProperties": false,
|
|
199
|
+
"properties": {
|
|
200
|
+
"amount": {
|
|
201
|
+
"type": "number"
|
|
202
|
+
},
|
|
203
|
+
"id": {
|
|
204
|
+
"type": "string"
|
|
205
|
+
},
|
|
206
|
+
"type": {
|
|
207
|
+
"const": "item",
|
|
208
|
+
"type": "string"
|
|
209
|
+
}
|
|
210
|
+
},
|
|
211
|
+
"required": ["amount", "id", "type"],
|
|
212
|
+
"type": "object"
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
"type": "null"
|
|
216
|
+
}
|
|
118
217
|
]
|
|
119
218
|
},
|
|
219
|
+
"maxItems": 9,
|
|
220
|
+
"minItems": 9,
|
|
120
221
|
"type": "array"
|
|
121
222
|
},
|
|
122
223
|
"type": {
|
|
123
|
-
"const": "workbench"
|
|
124
|
-
|
|
125
|
-
},
|
|
126
|
-
"required": ["type", "grid"],
|
|
127
|
-
"type": "object"
|
|
128
|
-
},
|
|
129
|
-
{
|
|
130
|
-
"additionalProperties": false,
|
|
131
|
-
"properties": {
|
|
132
|
-
"left": {
|
|
133
|
-
"$ref": "#/definitions/itemAction",
|
|
134
|
-
"type": "object"
|
|
135
|
-
},
|
|
136
|
-
"right": {
|
|
137
|
-
"$ref": "#/definitions/itemAction",
|
|
138
|
-
"type": "object"
|
|
139
|
-
},
|
|
140
|
-
"type": {
|
|
141
|
-
"const": "anvil"
|
|
224
|
+
"const": "workbench",
|
|
225
|
+
"type": "string"
|
|
142
226
|
}
|
|
143
227
|
},
|
|
144
|
-
"required": ["
|
|
228
|
+
"required": ["grid", "type"],
|
|
145
229
|
"type": "object"
|
|
146
230
|
}
|
|
147
|
-
]
|
|
148
|
-
"type": "object"
|
|
231
|
+
]
|
|
149
232
|
},
|
|
150
233
|
"type": "array"
|
|
151
|
-
},
|
|
152
|
-
"requirements": {
|
|
153
|
-
"items": {},
|
|
154
|
-
"type": "array"
|
|
155
234
|
}
|
|
156
235
|
},
|
|
157
236
|
"required": ["inputs", "outputs", "place"],
|
package/data/gems.json
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
"$schema": "./$schema.json",
|
|
3
3
|
"actions": [
|
|
4
4
|
{
|
|
5
|
-
"inputs": [{ "amount":
|
|
6
|
-
"outputs": [{ "amount":
|
|
5
|
+
"inputs": [{ "amount": 5.99, "id": "usd", "type": "currency" }],
|
|
6
|
+
"outputs": [{ "amount": 700, "id": "gem", "type": "currency" }],
|
|
7
7
|
"place": [
|
|
8
8
|
{
|
|
9
9
|
"id": "ELIZABETH",
|
|
@@ -16,8 +16,8 @@
|
|
|
16
16
|
]
|
|
17
17
|
},
|
|
18
18
|
{
|
|
19
|
-
"inputs": [{ "amount":
|
|
20
|
-
"outputs": [{ "amount":
|
|
19
|
+
"inputs": [{ "amount": 14.99, "id": "usd", "type": "currency" }],
|
|
20
|
+
"outputs": [{ "amount": 1800, "id": "gem", "type": "currency" }],
|
|
21
21
|
"place": [
|
|
22
22
|
{
|
|
23
23
|
"id": "ELIZABETH",
|
|
@@ -30,8 +30,8 @@
|
|
|
30
30
|
]
|
|
31
31
|
},
|
|
32
32
|
{
|
|
33
|
-
"inputs": [{ "amount":
|
|
34
|
-
"outputs": [{ "amount":
|
|
33
|
+
"inputs": [{ "amount": 29.99, "id": "usd", "type": "currency" }],
|
|
34
|
+
"outputs": [{ "amount": 3750, "id": "gem", "type": "currency" }],
|
|
35
35
|
"place": [
|
|
36
36
|
{
|
|
37
37
|
"id": "ELIZABETH",
|
|
@@ -44,8 +44,8 @@
|
|
|
44
44
|
]
|
|
45
45
|
},
|
|
46
46
|
{
|
|
47
|
-
"inputs": [{ "amount":
|
|
48
|
-
"outputs": [{ "amount":
|
|
47
|
+
"inputs": [{ "amount": 59.99, "id": "usd", "type": "currency" }],
|
|
48
|
+
"outputs": [{ "amount": 7600, "id": "gem", "type": "currency" }],
|
|
49
49
|
"place": [
|
|
50
50
|
{
|
|
51
51
|
"id": "ELIZABETH",
|
|
@@ -58,8 +58,8 @@
|
|
|
58
58
|
]
|
|
59
59
|
},
|
|
60
60
|
{
|
|
61
|
-
"inputs": [{ "amount":
|
|
62
|
-
"outputs": [{ "amount":
|
|
61
|
+
"inputs": [{ "amount": 119.99, "id": "usd", "type": "currency" }],
|
|
62
|
+
"outputs": [{ "amount": 17000, "id": "gem", "type": "currency" }],
|
|
63
63
|
"place": [
|
|
64
64
|
{
|
|
65
65
|
"id": "ELIZABETH",
|