@bscotch/yy 0.2.1 → 0.3.1

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.
Files changed (58) hide show
  1. package/README.md +5 -1
  2. package/dist/Schema.d.ts +1 -0
  3. package/dist/Schema.d.ts.map +1 -0
  4. package/dist/Schema.js +2 -0
  5. package/dist/Schema.js.map +1 -0
  6. package/dist/Yy.d.ts +4417 -9
  7. package/dist/Yy.d.ts.map +1 -1
  8. package/dist/Yy.js +142 -24
  9. package/dist/Yy.js.map +1 -1
  10. package/dist/Yy.parse.d.ts +2 -1
  11. package/dist/Yy.parse.d.ts.map +1 -1
  12. package/dist/Yy.parse.js +3 -3
  13. package/dist/Yy.parse.js.map +1 -1
  14. package/dist/Yy.stringify.d.ts +2 -1
  15. package/dist/Yy.stringify.d.ts.map +1 -1
  16. package/dist/Yy.stringify.js +11 -12
  17. package/dist/Yy.stringify.js.map +1 -1
  18. package/dist/index.d.ts +7 -0
  19. package/dist/index.d.ts.map +1 -1
  20. package/dist/index.js +7 -0
  21. package/dist/index.js.map +1 -1
  22. package/dist/types/YyBase.d.ts +47 -0
  23. package/dist/types/YyBase.d.ts.map +1 -0
  24. package/dist/types/YyBase.js +38 -0
  25. package/dist/types/YyBase.js.map +1 -0
  26. package/dist/types/YyObject.d.ts +463 -0
  27. package/dist/types/YyObject.d.ts.map +1 -0
  28. package/dist/types/YyObject.js +109 -0
  29. package/dist/types/YyObject.js.map +1 -0
  30. package/dist/types/YyRoom.d.ts +1544 -0
  31. package/dist/types/YyRoom.d.ts.map +1 -0
  32. package/dist/types/YyRoom.js +156 -0
  33. package/dist/types/YyRoom.js.map +1 -0
  34. package/dist/types/YyScript.d.ts +48 -0
  35. package/dist/types/YyScript.d.ts.map +1 -0
  36. package/dist/types/YyScript.js +9 -0
  37. package/dist/types/YyScript.js.map +1 -0
  38. package/dist/types/YySound.d.ts +116 -0
  39. package/dist/types/YySound.d.ts.map +1 -0
  40. package/dist/types/YySound.js +62 -0
  41. package/dist/types/YySound.js.map +1 -0
  42. package/dist/types/YySprite.d.ts +7829 -0
  43. package/dist/types/YySprite.d.ts.map +1 -0
  44. package/dist/types/YySprite.js +410 -0
  45. package/dist/types/YySprite.js.map +1 -0
  46. package/dist/types/YySprite.lib.d.ts +421 -0
  47. package/dist/types/YySprite.lib.d.ts.map +1 -0
  48. package/dist/types/YySprite.lib.js +27 -0
  49. package/dist/types/YySprite.lib.js.map +1 -0
  50. package/dist/types/Yyp.d.ts +589 -0
  51. package/dist/types/Yyp.d.ts.map +1 -0
  52. package/dist/types/Yyp.js +100 -0
  53. package/dist/types/Yyp.js.map +1 -0
  54. package/dist/types/utility.d.ts +74 -0
  55. package/dist/types/utility.d.ts.map +1 -0
  56. package/dist/types/utility.js +105 -0
  57. package/dist/types/utility.js.map +1 -0
  58. package/package.json +11 -5
@@ -0,0 +1,589 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * @file Typings for components of a freshly-parsed YYP file,
4
+ * when it is stored as a collection of plain objects.
5
+ * See {@link ./Gms2ProjectComponents.ts} for typings related
6
+ * to when the vanilla content has been replaced with class
7
+ * instances.
8
+ */
9
+ export type YypResourceId = z.infer<typeof yypResourceIdSchema>;
10
+ export declare const yypResourceIdSchema: z.ZodObject<{
11
+ name: z.ZodString;
12
+ path: z.ZodString;
13
+ }, "strip", z.ZodTypeAny, {
14
+ path: string;
15
+ name: string;
16
+ }, {
17
+ path: string;
18
+ name: string;
19
+ }>;
20
+ /** A 'Resource' is a an asset like a sprite, object, script, and so on. */
21
+ export type YypResource = z.infer<typeof yypResourceSchema>;
22
+ declare const yypResourceSchema: z.ZodObject<{
23
+ id: z.ZodObject<{
24
+ name: z.ZodString;
25
+ path: z.ZodString;
26
+ }, "strip", z.ZodTypeAny, {
27
+ path: string;
28
+ name: string;
29
+ }, {
30
+ path: string;
31
+ name: string;
32
+ }>;
33
+ order: z.ZodDefault<z.ZodNumber>;
34
+ }, "strip", z.ZodTypeAny, {
35
+ id: {
36
+ path: string;
37
+ name: string;
38
+ };
39
+ order: number;
40
+ }, {
41
+ order?: number | undefined;
42
+ id: {
43
+ path: string;
44
+ name: string;
45
+ };
46
+ }>;
47
+ export type YypOption = z.infer<typeof yypOptionSchema>;
48
+ declare const yypOptionSchema: z.ZodObject<{
49
+ ConfigValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodString>>>;
50
+ name: z.ZodString;
51
+ path: z.ZodString;
52
+ }, "strip", z.ZodTypeAny, {
53
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
54
+ path: string;
55
+ name: string;
56
+ }, {
57
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
58
+ path: string;
59
+ name: string;
60
+ }>;
61
+ export interface YypConfig {
62
+ name: string;
63
+ children: YypConfig[];
64
+ }
65
+ export type YypRoomOrderNode = z.infer<typeof yypRoomOrderNodeSchema>;
66
+ declare const yypRoomOrderNodeSchema: z.ZodObject<{
67
+ roomId: z.ZodObject<{
68
+ name: z.ZodString;
69
+ /** rooms/{name}/{name}.yy */
70
+ path: z.ZodString;
71
+ }, "strip", z.ZodTypeAny, {
72
+ path: string;
73
+ name: string;
74
+ }, {
75
+ path: string;
76
+ name: string;
77
+ }>;
78
+ }, "strip", z.ZodTypeAny, {
79
+ roomId: {
80
+ path: string;
81
+ name: string;
82
+ };
83
+ }, {
84
+ roomId: {
85
+ path: string;
86
+ name: string;
87
+ };
88
+ }>;
89
+ export type YypFolder = z.infer<typeof yypFolderSchema>;
90
+ declare const yypFolderSchema: z.ZodObject<{
91
+ name: z.ZodString;
92
+ tags: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
93
+ folderPath: z.ZodString;
94
+ order: z.ZodDefault<z.ZodNumber>;
95
+ resourceType: z.ZodDefault<z.ZodLiteral<"GMFolder">>;
96
+ resourceVersion: z.ZodDefault<z.ZodLiteral<"1.0">>;
97
+ }, "strip", z.ZodTypeAny, {
98
+ tags?: string[] | undefined;
99
+ name: string;
100
+ resourceType: "GMFolder";
101
+ resourceVersion: "1.0";
102
+ order: number;
103
+ folderPath: string;
104
+ }, {
105
+ resourceType?: "GMFolder" | undefined;
106
+ tags?: string[] | undefined;
107
+ resourceVersion?: "1.0" | undefined;
108
+ order?: number | undefined;
109
+ name: string;
110
+ folderPath: string;
111
+ }>;
112
+ export type YypAudioGroup = z.infer<typeof yypAudioGroupSchema>;
113
+ export type YypAudioGroupLoose = z.input<typeof yypAudioGroupSchema>;
114
+ export declare const yypAudioGroupSchema: z.ZodObject<{
115
+ ConfigValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodString>>>;
116
+ name: z.ZodString;
117
+ targets: z.ZodDefault<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodBigInt]>, bigint, number | bigint>>;
118
+ resourceType: z.ZodDefault<z.ZodLiteral<"GMAudioGroup">>;
119
+ resourceVersion: z.ZodDefault<z.ZodLiteral<"1.3">>;
120
+ }, "strip", z.ZodTypeAny, {
121
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
122
+ name: string;
123
+ resourceType: "GMAudioGroup";
124
+ resourceVersion: "1.3";
125
+ targets: bigint;
126
+ }, {
127
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
128
+ resourceType?: "GMAudioGroup" | undefined;
129
+ resourceVersion?: "1.3" | undefined;
130
+ targets?: number | bigint | undefined;
131
+ name: string;
132
+ }>;
133
+ export type YypTextureGroup = z.infer<typeof yypTextureGroupSchema>;
134
+ export declare const yypTextureGroupSchema: z.ZodObject<{
135
+ ConfigValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodString>>>;
136
+ name: z.ZodString;
137
+ groupParent: z.ZodDefault<z.ZodNullable<z.ZodObject<{
138
+ name: z.ZodString;
139
+ path: z.ZodString;
140
+ }, "strip", z.ZodTypeAny, {
141
+ path: string;
142
+ name: string;
143
+ }, {
144
+ path: string;
145
+ name: string;
146
+ }>>>;
147
+ isScaled: z.ZodDefault<z.ZodBoolean>;
148
+ compressFormat: z.ZodOptional<z.ZodString>;
149
+ autocrop: z.ZodDefault<z.ZodBoolean>;
150
+ border: z.ZodDefault<z.ZodNumber>;
151
+ mipsToGenerate: z.ZodDefault<z.ZodNumber>;
152
+ targets: z.ZodDefault<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodBigInt]>, bigint, number | bigint>>;
153
+ resourceType: z.ZodDefault<z.ZodLiteral<"GMTextureGroup">>;
154
+ resourceVersion: z.ZodDefault<z.ZodLiteral<"1.3">>;
155
+ }, "strip", z.ZodTypeAny, {
156
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
157
+ compressFormat?: string | undefined;
158
+ name: string;
159
+ resourceType: "GMTextureGroup";
160
+ resourceVersion: "1.3";
161
+ targets: bigint;
162
+ groupParent: {
163
+ path: string;
164
+ name: string;
165
+ } | null;
166
+ isScaled: boolean;
167
+ autocrop: boolean;
168
+ border: number;
169
+ mipsToGenerate: number;
170
+ }, {
171
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
172
+ resourceType?: "GMTextureGroup" | undefined;
173
+ resourceVersion?: "1.3" | undefined;
174
+ targets?: number | bigint | undefined;
175
+ groupParent?: {
176
+ path: string;
177
+ name: string;
178
+ } | null | undefined;
179
+ isScaled?: boolean | undefined;
180
+ compressFormat?: string | undefined;
181
+ autocrop?: boolean | undefined;
182
+ border?: number | undefined;
183
+ mipsToGenerate?: number | undefined;
184
+ name: string;
185
+ }>;
186
+ export type YypIncludedFile = z.infer<typeof yypIncludedFileSchema>;
187
+ declare const yypIncludedFileSchema: z.ZodObject<{
188
+ ConfigValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
189
+ CopyToMask: z.ZodString;
190
+ }, "strip", z.ZodTypeAny, {
191
+ CopyToMask: string;
192
+ }, {
193
+ CopyToMask: string;
194
+ }>>>;
195
+ /** The name of the file, including extension, without the path */
196
+ name: z.ZodString;
197
+ CopyToMask: z.ZodDefault<z.ZodNumber>;
198
+ /** `datafiles/${subdir}` */
199
+ filePath: z.ZodString;
200
+ resourceType: z.ZodDefault<z.ZodLiteral<"GMIncludedFile">>;
201
+ resourceVersion: z.ZodDefault<z.ZodLiteral<"1.0">>;
202
+ }, "strip", z.ZodTypeAny, {
203
+ ConfigValues?: Record<string, {
204
+ CopyToMask: string;
205
+ }> | undefined;
206
+ name: string;
207
+ resourceType: "GMIncludedFile";
208
+ resourceVersion: "1.0";
209
+ CopyToMask: number;
210
+ filePath: string;
211
+ }, {
212
+ ConfigValues?: Record<string, {
213
+ CopyToMask: string;
214
+ }> | undefined;
215
+ resourceType?: "GMIncludedFile" | undefined;
216
+ resourceVersion?: "1.0" | undefined;
217
+ CopyToMask?: number | undefined;
218
+ name: string;
219
+ filePath: string;
220
+ }>;
221
+ /** The YYP content that has not changed across GMS2.3 subversions */
222
+ export type Yyp = z.infer<typeof yypSchema>;
223
+ export declare const yypSchema: z.ZodObject<{
224
+ name: z.ZodString;
225
+ resourceType: z.ZodDefault<z.ZodLiteral<"GMProject">>;
226
+ resources: z.ZodDefault<z.ZodArray<z.ZodObject<{
227
+ id: z.ZodObject<{
228
+ name: z.ZodString;
229
+ path: z.ZodString;
230
+ }, "strip", z.ZodTypeAny, {
231
+ path: string;
232
+ name: string;
233
+ }, {
234
+ path: string;
235
+ name: string;
236
+ }>;
237
+ order: z.ZodDefault<z.ZodNumber>;
238
+ }, "strip", z.ZodTypeAny, {
239
+ id: {
240
+ path: string;
241
+ name: string;
242
+ };
243
+ order: number;
244
+ }, {
245
+ order?: number | undefined;
246
+ id: {
247
+ path: string;
248
+ name: string;
249
+ };
250
+ }>, "many">>;
251
+ RoomOrderNodes: z.ZodDefault<z.ZodArray<z.ZodObject<{
252
+ roomId: z.ZodObject<{
253
+ name: z.ZodString;
254
+ /** rooms/{name}/{name}.yy */
255
+ path: z.ZodString;
256
+ }, "strip", z.ZodTypeAny, {
257
+ path: string;
258
+ name: string;
259
+ }, {
260
+ path: string;
261
+ name: string;
262
+ }>;
263
+ }, "strip", z.ZodTypeAny, {
264
+ roomId: {
265
+ path: string;
266
+ name: string;
267
+ };
268
+ }, {
269
+ roomId: {
270
+ path: string;
271
+ name: string;
272
+ };
273
+ }>, "many">>;
274
+ Options: z.ZodDefault<z.ZodArray<z.ZodObject<{
275
+ ConfigValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodString>>>;
276
+ name: z.ZodString;
277
+ path: z.ZodString;
278
+ }, "strip", z.ZodTypeAny, {
279
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
280
+ path: string;
281
+ name: string;
282
+ }, {
283
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
284
+ path: string;
285
+ name: string;
286
+ }>, "many">>;
287
+ isDnDProject: z.ZodOptional<z.ZodBoolean>;
288
+ defaultScriptType: z.ZodDefault<z.ZodNumber>;
289
+ isEcma: z.ZodDefault<z.ZodBoolean>;
290
+ tutorialPath: z.ZodOptional<z.ZodString>;
291
+ configs: z.ZodObject<{
292
+ name: z.ZodDefault<z.ZodLiteral<"Default">>;
293
+ children: z.ZodDefault<z.ZodArray<z.ZodType<YypConfig, z.ZodTypeDef, YypConfig>, "many">>;
294
+ }, "strip", z.ZodTypeAny, {
295
+ name: "Default";
296
+ children: YypConfig[];
297
+ }, {
298
+ name?: "Default" | undefined;
299
+ children?: YypConfig[] | undefined;
300
+ }>;
301
+ Folders: z.ZodDefault<z.ZodArray<z.ZodObject<{
302
+ name: z.ZodString;
303
+ tags: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
304
+ folderPath: z.ZodString;
305
+ order: z.ZodDefault<z.ZodNumber>;
306
+ resourceType: z.ZodDefault<z.ZodLiteral<"GMFolder">>;
307
+ resourceVersion: z.ZodDefault<z.ZodLiteral<"1.0">>;
308
+ }, "strip", z.ZodTypeAny, {
309
+ tags?: string[] | undefined;
310
+ name: string;
311
+ resourceType: "GMFolder";
312
+ resourceVersion: "1.0";
313
+ order: number;
314
+ folderPath: string;
315
+ }, {
316
+ resourceType?: "GMFolder" | undefined;
317
+ tags?: string[] | undefined;
318
+ resourceVersion?: "1.0" | undefined;
319
+ order?: number | undefined;
320
+ name: string;
321
+ folderPath: string;
322
+ }>, "many">>;
323
+ AudioGroups: z.ZodDefault<z.ZodArray<z.ZodObject<{
324
+ ConfigValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodString>>>;
325
+ name: z.ZodString;
326
+ targets: z.ZodDefault<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodBigInt]>, bigint, number | bigint>>;
327
+ resourceType: z.ZodDefault<z.ZodLiteral<"GMAudioGroup">>;
328
+ resourceVersion: z.ZodDefault<z.ZodLiteral<"1.3">>;
329
+ }, "strip", z.ZodTypeAny, {
330
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
331
+ name: string;
332
+ resourceType: "GMAudioGroup";
333
+ resourceVersion: "1.3";
334
+ targets: bigint;
335
+ }, {
336
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
337
+ resourceType?: "GMAudioGroup" | undefined;
338
+ resourceVersion?: "1.3" | undefined;
339
+ targets?: number | bigint | undefined;
340
+ name: string;
341
+ }>, "many">>;
342
+ TextureGroups: z.ZodDefault<z.ZodArray<z.ZodObject<{
343
+ ConfigValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodString>>>;
344
+ name: z.ZodString;
345
+ groupParent: z.ZodDefault<z.ZodNullable<z.ZodObject<{
346
+ name: z.ZodString;
347
+ path: z.ZodString;
348
+ }, "strip", z.ZodTypeAny, {
349
+ path: string;
350
+ name: string;
351
+ }, {
352
+ path: string;
353
+ name: string;
354
+ }>>>;
355
+ isScaled: z.ZodDefault<z.ZodBoolean>;
356
+ compressFormat: z.ZodOptional<z.ZodString>;
357
+ autocrop: z.ZodDefault<z.ZodBoolean>;
358
+ border: z.ZodDefault<z.ZodNumber>;
359
+ mipsToGenerate: z.ZodDefault<z.ZodNumber>;
360
+ targets: z.ZodDefault<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodBigInt]>, bigint, number | bigint>>;
361
+ resourceType: z.ZodDefault<z.ZodLiteral<"GMTextureGroup">>;
362
+ resourceVersion: z.ZodDefault<z.ZodLiteral<"1.3">>;
363
+ }, "strip", z.ZodTypeAny, {
364
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
365
+ compressFormat?: string | undefined;
366
+ name: string;
367
+ resourceType: "GMTextureGroup";
368
+ resourceVersion: "1.3";
369
+ targets: bigint;
370
+ groupParent: {
371
+ path: string;
372
+ name: string;
373
+ } | null;
374
+ isScaled: boolean;
375
+ autocrop: boolean;
376
+ border: number;
377
+ mipsToGenerate: number;
378
+ }, {
379
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
380
+ resourceType?: "GMTextureGroup" | undefined;
381
+ resourceVersion?: "1.3" | undefined;
382
+ targets?: number | bigint | undefined;
383
+ groupParent?: {
384
+ path: string;
385
+ name: string;
386
+ } | null | undefined;
387
+ isScaled?: boolean | undefined;
388
+ compressFormat?: string | undefined;
389
+ autocrop?: boolean | undefined;
390
+ border?: number | undefined;
391
+ mipsToGenerate?: number | undefined;
392
+ name: string;
393
+ }>, "many">>;
394
+ IncludedFiles: z.ZodDefault<z.ZodArray<z.ZodObject<{
395
+ ConfigValues: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
396
+ CopyToMask: z.ZodString;
397
+ }, "strip", z.ZodTypeAny, {
398
+ CopyToMask: string;
399
+ }, {
400
+ CopyToMask: string;
401
+ }>>>;
402
+ /** The name of the file, including extension, without the path */
403
+ name: z.ZodString;
404
+ CopyToMask: z.ZodDefault<z.ZodNumber>;
405
+ /** `datafiles/${subdir}` */
406
+ filePath: z.ZodString;
407
+ resourceType: z.ZodDefault<z.ZodLiteral<"GMIncludedFile">>;
408
+ resourceVersion: z.ZodDefault<z.ZodLiteral<"1.0">>;
409
+ }, "strip", z.ZodTypeAny, {
410
+ ConfigValues?: Record<string, {
411
+ CopyToMask: string;
412
+ }> | undefined;
413
+ name: string;
414
+ resourceType: "GMIncludedFile";
415
+ resourceVersion: "1.0";
416
+ CopyToMask: number;
417
+ filePath: string;
418
+ }, {
419
+ ConfigValues?: Record<string, {
420
+ CopyToMask: string;
421
+ }> | undefined;
422
+ resourceType?: "GMIncludedFile" | undefined;
423
+ resourceVersion?: "1.0" | undefined;
424
+ CopyToMask?: number | undefined;
425
+ name: string;
426
+ filePath: string;
427
+ }>, "many">>;
428
+ MetaData: z.ZodObject<{
429
+ IDEVersion: z.ZodString;
430
+ }, "strip", z.ZodTypeAny, {
431
+ IDEVersion: string;
432
+ }, {
433
+ IDEVersion: string;
434
+ }>;
435
+ resourceVersion: z.ZodString;
436
+ tags: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
437
+ }, "strip", z.ZodTypeAny, {
438
+ tags?: string[] | undefined;
439
+ isDnDProject?: boolean | undefined;
440
+ tutorialPath?: string | undefined;
441
+ name: string;
442
+ resourceType: "GMProject";
443
+ resourceVersion: string;
444
+ resources: {
445
+ id: {
446
+ path: string;
447
+ name: string;
448
+ };
449
+ order: number;
450
+ }[];
451
+ RoomOrderNodes: {
452
+ roomId: {
453
+ path: string;
454
+ name: string;
455
+ };
456
+ }[];
457
+ Options: {
458
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
459
+ path: string;
460
+ name: string;
461
+ }[];
462
+ defaultScriptType: number;
463
+ isEcma: boolean;
464
+ configs: {
465
+ name: "Default";
466
+ children: YypConfig[];
467
+ };
468
+ Folders: {
469
+ tags?: string[] | undefined;
470
+ name: string;
471
+ resourceType: "GMFolder";
472
+ resourceVersion: "1.0";
473
+ order: number;
474
+ folderPath: string;
475
+ }[];
476
+ AudioGroups: {
477
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
478
+ name: string;
479
+ resourceType: "GMAudioGroup";
480
+ resourceVersion: "1.3";
481
+ targets: bigint;
482
+ }[];
483
+ TextureGroups: {
484
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
485
+ compressFormat?: string | undefined;
486
+ name: string;
487
+ resourceType: "GMTextureGroup";
488
+ resourceVersion: "1.3";
489
+ targets: bigint;
490
+ groupParent: {
491
+ path: string;
492
+ name: string;
493
+ } | null;
494
+ isScaled: boolean;
495
+ autocrop: boolean;
496
+ border: number;
497
+ mipsToGenerate: number;
498
+ }[];
499
+ IncludedFiles: {
500
+ ConfigValues?: Record<string, {
501
+ CopyToMask: string;
502
+ }> | undefined;
503
+ name: string;
504
+ resourceType: "GMIncludedFile";
505
+ resourceVersion: "1.0";
506
+ CopyToMask: number;
507
+ filePath: string;
508
+ }[];
509
+ MetaData: {
510
+ IDEVersion: string;
511
+ };
512
+ }, {
513
+ resourceType?: "GMProject" | undefined;
514
+ tags?: string[] | undefined;
515
+ resources?: {
516
+ order?: number | undefined;
517
+ id: {
518
+ path: string;
519
+ name: string;
520
+ };
521
+ }[] | undefined;
522
+ RoomOrderNodes?: {
523
+ roomId: {
524
+ path: string;
525
+ name: string;
526
+ };
527
+ }[] | undefined;
528
+ Options?: {
529
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
530
+ path: string;
531
+ name: string;
532
+ }[] | undefined;
533
+ isDnDProject?: boolean | undefined;
534
+ defaultScriptType?: number | undefined;
535
+ isEcma?: boolean | undefined;
536
+ tutorialPath?: string | undefined;
537
+ Folders?: {
538
+ resourceType?: "GMFolder" | undefined;
539
+ tags?: string[] | undefined;
540
+ resourceVersion?: "1.0" | undefined;
541
+ order?: number | undefined;
542
+ name: string;
543
+ folderPath: string;
544
+ }[] | undefined;
545
+ AudioGroups?: {
546
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
547
+ resourceType?: "GMAudioGroup" | undefined;
548
+ resourceVersion?: "1.3" | undefined;
549
+ targets?: number | bigint | undefined;
550
+ name: string;
551
+ }[] | undefined;
552
+ TextureGroups?: {
553
+ ConfigValues?: Record<string, Record<string, string>> | undefined;
554
+ resourceType?: "GMTextureGroup" | undefined;
555
+ resourceVersion?: "1.3" | undefined;
556
+ targets?: number | bigint | undefined;
557
+ groupParent?: {
558
+ path: string;
559
+ name: string;
560
+ } | null | undefined;
561
+ isScaled?: boolean | undefined;
562
+ compressFormat?: string | undefined;
563
+ autocrop?: boolean | undefined;
564
+ border?: number | undefined;
565
+ mipsToGenerate?: number | undefined;
566
+ name: string;
567
+ }[] | undefined;
568
+ IncludedFiles?: {
569
+ ConfigValues?: Record<string, {
570
+ CopyToMask: string;
571
+ }> | undefined;
572
+ resourceType?: "GMIncludedFile" | undefined;
573
+ resourceVersion?: "1.0" | undefined;
574
+ CopyToMask?: number | undefined;
575
+ name: string;
576
+ filePath: string;
577
+ }[] | undefined;
578
+ name: string;
579
+ resourceVersion: string;
580
+ configs: {
581
+ name?: "Default" | undefined;
582
+ children?: YypConfig[] | undefined;
583
+ };
584
+ MetaData: {
585
+ IDEVersion: string;
586
+ };
587
+ }>;
588
+ export {};
589
+ //# sourceMappingURL=Yyp.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Yyp.d.ts","sourceRoot":"","sources":["../../src/types/Yyp.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB;;;;;;GAMG;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAChE,eAAO,MAAM,mBAAmB;;;;;;;;;EAG9B,CAAC;AAEH,2EAA2E;AAC3E,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAC5D,QAAA,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;EAGrB,CAAC;AAEH,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AACxD,QAAA,MAAM,eAAe;;;;;;;;;;;;EAInB,CAAC;AAEH,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,SAAS,EAAE,CAAC;CACvB;AAQD,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AACtE,QAAA,MAAM,sBAAsB;;;QAGxB,6BAA6B;;;;;;;;;;;;;;;;;;;EAG/B,CAAC;AAEH,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AACxD,QAAA,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;EAOnB,CAAC;AAEH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAChE,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AACrE,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;EAM9B,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AACpE,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAkBhC,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AACpE,QAAA,MAAM,qBAAqB;;;;;;;;IAQzB,kEAAkE;;;IAGlE,4BAA4B;;;;;;;;;;;;;;;;;;;;;;EAI5B,CAAC;AAEH,qEAAqE;AACrE,MAAM,MAAM,GAAG,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,SAAS,CAAC,CAAC;AAC5C,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YAlElB,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAuD/B,kEAAkE;;;QAGlE,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+B5B,CAAC"}
@@ -0,0 +1,100 @@
1
+ // Generated by ts-to-zod
2
+ import { z } from 'zod';
3
+ import { bigNumber } from './utility.js';
4
+ export const yypResourceIdSchema = z.object({
5
+ name: z.string(),
6
+ path: z.string(),
7
+ });
8
+ const yypResourceSchema = z.object({
9
+ id: yypResourceIdSchema,
10
+ order: z.number().default(0),
11
+ });
12
+ const yypOptionSchema = z.object({
13
+ ConfigValues: z.record(z.record(z.string())).optional(),
14
+ name: z.string(),
15
+ path: z.string(),
16
+ });
17
+ const yypConfigSchema = z.lazy(() => z.object({
18
+ name: z.string(),
19
+ children: z.array(yypConfigSchema),
20
+ }));
21
+ const yypRoomOrderNodeSchema = z.object({
22
+ roomId: z.object({
23
+ name: z.string(),
24
+ /** rooms/{name}/{name}.yy */
25
+ path: z.string(),
26
+ }),
27
+ });
28
+ const yypFolderSchema = z.object({
29
+ name: z.string(),
30
+ tags: z.array(z.string()).optional(),
31
+ folderPath: z.string(),
32
+ order: z.number().default(1),
33
+ resourceType: z.literal('GMFolder').default('GMFolder'),
34
+ resourceVersion: z.literal('1.0').default('1.0'),
35
+ });
36
+ export const yypAudioGroupSchema = z.object({
37
+ ConfigValues: z.record(z.record(z.string())).optional(),
38
+ name: z.string(),
39
+ targets: bigNumber().default(461609314234257646n),
40
+ resourceType: z.literal('GMAudioGroup').default('GMAudioGroup'),
41
+ resourceVersion: z.literal('1.3').default('1.3'),
42
+ });
43
+ export const yypTextureGroupSchema = z.object({
44
+ ConfigValues: z.record(z.record(z.string())).optional(),
45
+ name: z.string(),
46
+ groupParent: z
47
+ .object({
48
+ name: z.string(),
49
+ path: z.string(),
50
+ })
51
+ .nullable()
52
+ .default(null),
53
+ isScaled: z.boolean().default(true),
54
+ compressFormat: z.string().optional(),
55
+ autocrop: z.boolean().default(true),
56
+ border: z.number().default(2),
57
+ mipsToGenerate: z.number().default(0),
58
+ targets: bigNumber().default(461609314234257646n),
59
+ resourceType: z.literal('GMTextureGroup').default('GMTextureGroup'),
60
+ resourceVersion: z.literal('1.3').default('1.3'),
61
+ });
62
+ const yypIncludedFileSchema = z.object({
63
+ ConfigValues: z
64
+ .record(z.object({
65
+ CopyToMask: z.string(),
66
+ }))
67
+ .optional(),
68
+ /** The name of the file, including extension, without the path */
69
+ name: z.string(),
70
+ CopyToMask: z.number().default(-1),
71
+ /** `datafiles/${subdir}` */
72
+ filePath: z.string(),
73
+ resourceType: z.literal('GMIncludedFile').default('GMIncludedFile'),
74
+ resourceVersion: z.literal('1.0').default('1.0'),
75
+ });
76
+ export const yypSchema = z.object({
77
+ name: z.string(),
78
+ resourceType: z.literal('GMProject').default('GMProject'),
79
+ resources: z.array(yypResourceSchema).default([]),
80
+ RoomOrderNodes: z.array(yypRoomOrderNodeSchema).default([]),
81
+ Options: z.array(yypOptionSchema).default([]),
82
+ isDnDProject: z.boolean().optional(),
83
+ defaultScriptType: z.number().default(1),
84
+ isEcma: z.boolean().default(false),
85
+ tutorialPath: z.string().optional(),
86
+ configs: z.object({
87
+ name: z.literal('Default').default('Default'),
88
+ children: z.array(yypConfigSchema).default([]),
89
+ }),
90
+ Folders: z.array(yypFolderSchema).default([]),
91
+ AudioGroups: z.array(yypAudioGroupSchema).default([]),
92
+ TextureGroups: z.array(yypTextureGroupSchema).default([]),
93
+ IncludedFiles: z.array(yypIncludedFileSchema).default([]),
94
+ MetaData: z.object({
95
+ IDEVersion: z.string(),
96
+ }),
97
+ resourceVersion: z.string(),
98
+ tags: z.array(z.string()).optional(),
99
+ });
100
+ //# sourceMappingURL=Yyp.js.map