@zthun/romulator-client 1.4.0 → 1.6.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.
@@ -8,7 +8,7 @@ export interface IZRomulatorGame {
8
8
  *
9
9
  * This is unique across all games and all systems.
10
10
  */
11
- id?: string;
11
+ id: string;
12
12
  /**
13
13
  * The name of the game.
14
14
  *
package/dist/index.cjs CHANGED
@@ -40,32 +40,6 @@ class ZRomulatorConfigGamesBuilder {
40
40
  }
41
41
  }
42
42
 
43
- class ZRomulatorConfigMediaMetadata {
44
- static all() {
45
- return [
46
- ZRomulatorConfigMediaMetadata.mediaFolder()
47
- ];
48
- }
49
- static mediaFolder() {
50
- return new helpfulQuery.ZMetadataBuilder().id("media-folder").path("mediaFolder").name("Media Folder").fallback("${HOME}/Games/.media").editable().file().build();
51
- }
52
- }
53
-
54
- class ZRomulatorConfigMediaBuilder {
55
- _media = {};
56
- mediaFolder(folder) {
57
- this._media.mediaFolder = folder;
58
- return this;
59
- }
60
- copy(other) {
61
- this._media = structuredClone(other);
62
- return this;
63
- }
64
- build() {
65
- return structuredClone(this._media);
66
- }
67
- }
68
-
69
43
  /**
70
44
  * Represents a list of known config ids
71
45
  */ var ZRomulatorConfigId = /*#__PURE__*/ function(ZRomulatorConfigId) {
@@ -124,7 +98,9 @@ class ZRomulatorConfigBuilder {
124
98
  /**
125
99
  * A builder for the IZRomulatorGame model.
126
100
  */ class ZRomulatorGameBuilder {
127
- _game = {};
101
+ _game = {
102
+ id: ""
103
+ };
128
104
  /**
129
105
  * Sets the unique id for the game.
130
106
  *
@@ -191,92 +167,279 @@ class ZRomulatorConfigBuilder {
191
167
  }
192
168
  }
193
169
 
194
- /**
195
- * Describes what a specific piece of media represents.
196
- */ var ZRomulatorMediaType = /*#__PURE__*/ function(ZRomulatorMediaType) {
170
+ var ZRomulatorGameMediaType = /*#__PURE__*/ function(ZRomulatorGameMediaType) {
197
171
  /**
198
172
  * A 3d representation of the box art.
199
- */ ZRomulatorMediaType["Game3dBox"] = "3dboxes";
173
+ */ ZRomulatorGameMediaType["Box3d"] = "3dboxes";
200
174
  /**
201
175
  * Back of the game box.
202
- */ ZRomulatorMediaType["GameBackCover"] = "backcovers";
176
+ */ ZRomulatorGameMediaType["BackCover"] = "backcovers";
203
177
  /**
204
178
  * Front of the game box.
205
- */ ZRomulatorMediaType["GameCover"] = "covers";
179
+ */ ZRomulatorGameMediaType["Cover"] = "covers";
206
180
  /**
207
181
  * Fan art.
208
- */ ZRomulatorMediaType["GameFanArt"] = "fanart";
182
+ */ ZRomulatorGameMediaType["FanArt"] = "fanart";
209
183
  /**
210
184
  * Game manual.
211
- */ ZRomulatorMediaType["GameManual"] = "manuals";
185
+ */ ZRomulatorGameMediaType["Manual"] = "manuals";
212
186
  /**
213
187
  * A marquee of a game.
214
- */ ZRomulatorMediaType["GameMarquee"] = "marquees";
188
+ */ ZRomulatorGameMediaType["Marquee"] = "marquees";
215
189
  /**
216
190
  * The cartridge or disc label.
217
- */ ZRomulatorMediaType["GamePhysicalMedia"] = "physicalmedia";
191
+ */ ZRomulatorGameMediaType["PhysicalMedia"] = "physicalmedia";
218
192
  /**
219
193
  * An in game screenshot showcasing gameplay.
220
- */ ZRomulatorMediaType["GameScreenshot"] = "screenshots";
194
+ */ ZRomulatorGameMediaType["Screenshot"] = "screenshots";
221
195
  /**
222
196
  * An in game screenshot of the title screen.
223
- */ ZRomulatorMediaType["GameTitle"] = "titlescreens";
197
+ */ ZRomulatorGameMediaType["Title"] = "titlescreens";
224
198
  /**
225
199
  * A video showcasing the game.
226
- */ ZRomulatorMediaType["GameVideo"] = "videos";
200
+ */ ZRomulatorGameMediaType["Video"] = "videos";
201
+ return ZRomulatorGameMediaType;
202
+ }({});
203
+ /**
204
+ * Media type for a system.
205
+ */ var ZRomulatorSystemMediaType = /*#__PURE__*/ function(ZRomulatorSystemMediaType) {
227
206
  /**
228
207
  * An image of a system's controller.
229
- */ ZRomulatorMediaType["SystemController"] = "controller.png";
208
+ */ ZRomulatorSystemMediaType["Controller"] = "controller.png";
230
209
  /**
231
210
  * A icon for the system.
232
211
  *
233
212
  * These are normally 32x32.
234
- */ ZRomulatorMediaType["SystemIcon"] = "icon.png";
213
+ */ ZRomulatorSystemMediaType["Icon"] = "icon.png";
235
214
  /**
236
215
  * An illustration of the system.
237
- */ ZRomulatorMediaType["SystemIllustration"] = "illustration.png";
216
+ */ ZRomulatorSystemMediaType["Illustration"] = "illustration.png";
238
217
  /**
239
218
  * A picture of the system.
240
219
  *
241
220
  * These are real life looking photos of what
242
221
  * a system looks like.
243
- */ ZRomulatorMediaType["SystemPicture"] = "picture.png";
222
+ */ ZRomulatorSystemMediaType["Picture"] = "picture.png";
223
+ /**
224
+ * A video trailer for the system.
225
+ */ ZRomulatorSystemMediaType["Video"] = "video.mp4";
244
226
  /**
245
227
  * A wheel for a system.
246
228
  *
247
229
  * This is basically the logo.
248
- */ ZRomulatorMediaType["SystemWheel"] = "wheel.png";
249
- return ZRomulatorMediaType;
230
+ */ ZRomulatorSystemMediaType["Wheel"] = "wheel.png";
231
+ return ZRomulatorSystemMediaType;
250
232
  }({});
251
- const ZRomulatorMediaTypeMap = lodashEs.keyBy(Object.values(ZRomulatorMediaType));
233
+ const ZRomulatorSystemMediaTypeMap = lodashEs.keyBy(Object.values(ZRomulatorSystemMediaType));
234
+ const ZRomulatorGameMediaTypeMap = lodashEs.keyBy(Object.values(ZRomulatorGameMediaType));
235
+ function isSystemMediaType(candidate) {
236
+ return typeof candidate === "string" && Object.prototype.hasOwnProperty.call(ZRomulatorSystemMediaTypeMap, candidate);
237
+ }
238
+ function isGameMediaType(candidate) {
239
+ return typeof candidate === "string" && Object.prototype.hasOwnProperty.call(ZRomulatorGameMediaTypeMap, candidate);
240
+ }
252
241
  function isMediaType(candidate) {
253
- return typeof candidate === "string" && Object.prototype.hasOwnProperty.call(ZRomulatorMediaTypeMap, candidate);
242
+ return isSystemMediaType(candidate) || isGameMediaType(candidate);
254
243
  }
255
244
 
256
245
  /**
257
246
  * Id slugs for supported systems.
258
247
  */ var ZRomulatorSystemId = /*#__PURE__*/ function(ZRomulatorSystemId) {
259
- /**
260
- * Nintendo Entertainment System
261
- */ ZRomulatorSystemId["Nintendo"] = "nes";
262
- /**
263
- * Super Nintendo Entertainment System.
264
- */ ZRomulatorSystemId["SuperNintendo"] = "snes";
265
- /**
266
- * Nintendo 64
267
- */ ZRomulatorSystemId["Nintendo64"] = "n64";
268
- /**
269
- * Nintendo GameCube
270
- */ ZRomulatorSystemId["GameCube"] = "gc";
271
- /**
272
- * Nintendo Wii
273
- */ ZRomulatorSystemId["Wii"] = "wii";
274
- /**
275
- * Nintendo Wii U
276
- */ ZRomulatorSystemId["WiiU"] = "wiiu";
277
- /**
278
- * Nintendo Switch
279
- */ ZRomulatorSystemId["Switch"] = "switch";
248
+ ZRomulatorSystemId["ThreeDo"] = "3do";
249
+ ZRomulatorSystemId["Adam"] = "adam";
250
+ ZRomulatorSystemId["AGS"] = "ags";
251
+ ZRomulatorSystemId["Amiga"] = "amiga";
252
+ ZRomulatorSystemId["Amiga1200"] = "amiga1200";
253
+ ZRomulatorSystemId["Amiga600"] = "amiga600";
254
+ ZRomulatorSystemId["AmigaCd32"] = "amigacd32";
255
+ ZRomulatorSystemId["AmstradCpc"] = "amstradcpc";
256
+ ZRomulatorSystemId["Android"] = "android";
257
+ ZRomulatorSystemId["AndroidApps"] = "androidapps";
258
+ ZRomulatorSystemId["AndroidGames"] = "androidgames";
259
+ ZRomulatorSystemId["Apple2"] = "apple2";
260
+ ZRomulatorSystemId["Apple2Gs"] = "apple2gs";
261
+ ZRomulatorSystemId["Arcade"] = "arcade";
262
+ ZRomulatorSystemId["Arcadia"] = "arcadia";
263
+ ZRomulatorSystemId["Archimedes"] = "archimedes";
264
+ ZRomulatorSystemId["Arduboy"] = "arduboy";
265
+ ZRomulatorSystemId["Astrocde"] = "astrocde";
266
+ ZRomulatorSystemId["Atari2600"] = "atari2600";
267
+ ZRomulatorSystemId["Atari5200"] = "atari5200";
268
+ ZRomulatorSystemId["Atari7800"] = "atari7800";
269
+ ZRomulatorSystemId["Atari800"] = "atari800";
270
+ ZRomulatorSystemId["AtariJaguar"] = "atarijaguar";
271
+ ZRomulatorSystemId["AtariJaguarCd"] = "atarijaguarcd";
272
+ ZRomulatorSystemId["AtariLynx"] = "atarilynx";
273
+ ZRomulatorSystemId["AtariSt"] = "atarist";
274
+ ZRomulatorSystemId["AtariXe"] = "atarixe";
275
+ ZRomulatorSystemId["Atomiswave"] = "atomiswave";
276
+ ZRomulatorSystemId["BbcMicro"] = "bbcmicro";
277
+ ZRomulatorSystemId["C64"] = "c64";
278
+ ZRomulatorSystemId["CdiMono1"] = "cdimono1";
279
+ ZRomulatorSystemId["Cdtv"] = "cdtv";
280
+ ZRomulatorSystemId["ChaiLove"] = "chailove";
281
+ ZRomulatorSystemId["ChannelF"] = "channelf";
282
+ ZRomulatorSystemId["Coco"] = "coco";
283
+ ZRomulatorSystemId["Colecovision"] = "colecovision";
284
+ ZRomulatorSystemId["ConsoleArcade"] = "consolearcade";
285
+ ZRomulatorSystemId["Cps"] = "cps";
286
+ ZRomulatorSystemId["Cps1"] = "cps1";
287
+ ZRomulatorSystemId["Cps2"] = "cps2";
288
+ ZRomulatorSystemId["Cps3"] = "cps3";
289
+ ZRomulatorSystemId["CrVision"] = "crvision";
290
+ ZRomulatorSystemId["Daphne"] = "daphne";
291
+ ZRomulatorSystemId["Desktop"] = "desktop";
292
+ ZRomulatorSystemId["Doom"] = "doom";
293
+ ZRomulatorSystemId["Dos"] = "dos";
294
+ ZRomulatorSystemId["Dragon32"] = "dragon32";
295
+ ZRomulatorSystemId["Dreamcast"] = "dreamcast";
296
+ ZRomulatorSystemId["EasyRpg"] = "easyrpg";
297
+ ZRomulatorSystemId["Electron"] = "electron";
298
+ ZRomulatorSystemId["Emulators"] = "emulators";
299
+ ZRomulatorSystemId["Epic"] = "epic";
300
+ ZRomulatorSystemId["Famicom"] = "famicom";
301
+ ZRomulatorSystemId["FBA"] = "fba";
302
+ ZRomulatorSystemId["FBNeo"] = "fbneo";
303
+ ZRomulatorSystemId["FDS"] = "fds";
304
+ ZRomulatorSystemId["Flash"] = "flash";
305
+ ZRomulatorSystemId["FM7"] = "fm7";
306
+ ZRomulatorSystemId["FMTowns"] = "fmtowns";
307
+ ZRomulatorSystemId["FPinball"] = "fpinball";
308
+ ZRomulatorSystemId["Gamate"] = "gamate";
309
+ ZRomulatorSystemId["GameAndWatch"] = "gameandwatch";
310
+ ZRomulatorSystemId["GameCom"] = "gamecom";
311
+ ZRomulatorSystemId["GameGear"] = "gamegear";
312
+ ZRomulatorSystemId["GB"] = "gb";
313
+ ZRomulatorSystemId["GBA"] = "gba";
314
+ ZRomulatorSystemId["GBC"] = "gbc";
315
+ ZRomulatorSystemId["GameCube"] = "gc";
316
+ ZRomulatorSystemId["Genesis"] = "genesis";
317
+ ZRomulatorSystemId["GMaster"] = "gmaster";
318
+ ZRomulatorSystemId["GX4000"] = "gx4000";
319
+ ZRomulatorSystemId["Intellivision"] = "intellivision";
320
+ ZRomulatorSystemId["J2ME"] = "j2me";
321
+ ZRomulatorSystemId["Kodi"] = "kodi";
322
+ ZRomulatorSystemId["Laserdisc"] = "laserdisc";
323
+ ZRomulatorSystemId["LcdGames"] = "lcdgames";
324
+ ZRomulatorSystemId["LowResNx"] = "lowresnx";
325
+ ZRomulatorSystemId["Lutris"] = "lutris";
326
+ ZRomulatorSystemId["Lutro"] = "lutro";
327
+ ZRomulatorSystemId["Macintosh"] = "macintosh";
328
+ ZRomulatorSystemId["Mame"] = "mame";
329
+ ZRomulatorSystemId["MameAdvMame"] = "mame-advmame";
330
+ ZRomulatorSystemId["Mark3"] = "mark3";
331
+ ZRomulatorSystemId["MasterSystem"] = "mastersystem";
332
+ ZRomulatorSystemId["MegaCd"] = "megacd";
333
+ ZRomulatorSystemId["MegaCdJp"] = "megacdjp";
334
+ ZRomulatorSystemId["MegaDrive"] = "megadrive";
335
+ ZRomulatorSystemId["MegaDriveJp"] = "megadrivejp";
336
+ ZRomulatorSystemId["MegaDuck"] = "megaduck";
337
+ ZRomulatorSystemId["MESS"] = "mess";
338
+ ZRomulatorSystemId["Model2"] = "model2";
339
+ ZRomulatorSystemId["Model3"] = "model3";
340
+ ZRomulatorSystemId["Moto"] = "moto";
341
+ ZRomulatorSystemId["MSX"] = "msx";
342
+ ZRomulatorSystemId["MSX1"] = "msx1";
343
+ ZRomulatorSystemId["MSX2"] = "msx2";
344
+ ZRomulatorSystemId["MSXTurbor"] = "msxturbor";
345
+ ZRomulatorSystemId["Mugen"] = "mugen";
346
+ ZRomulatorSystemId["Multivision"] = "multivision";
347
+ ZRomulatorSystemId["N3DS"] = "n3ds";
348
+ ZRomulatorSystemId["Nintendo64"] = "n64";
349
+ ZRomulatorSystemId["N64DD"] = "n64dd";
350
+ ZRomulatorSystemId["Naomi"] = "naomi";
351
+ ZRomulatorSystemId["Naomi2"] = "naomi2";
352
+ ZRomulatorSystemId["NaomiGd"] = "naomigd";
353
+ ZRomulatorSystemId["NDS"] = "nds";
354
+ ZRomulatorSystemId["NeoGeo"] = "neogeo";
355
+ ZRomulatorSystemId["NeoGeoCd"] = "neogeocd";
356
+ ZRomulatorSystemId["NeoGeoCdJp"] = "neogeocdjp";
357
+ ZRomulatorSystemId["Nintendo"] = "nes";
358
+ ZRomulatorSystemId["NGage"] = "ngage";
359
+ ZRomulatorSystemId["NeoGeoPocket"] = "ngp";
360
+ ZRomulatorSystemId["NeoGeoPocketColor"] = "ngpc";
361
+ ZRomulatorSystemId["Odyssey2"] = "odyssey2";
362
+ ZRomulatorSystemId["OpenBor"] = "openbor";
363
+ ZRomulatorSystemId["Oric"] = "oric";
364
+ ZRomulatorSystemId["Palm"] = "palm";
365
+ ZRomulatorSystemId["PC"] = "pc";
366
+ ZRomulatorSystemId["PC88"] = "pc88";
367
+ ZRomulatorSystemId["PC98"] = "pc98";
368
+ ZRomulatorSystemId["PcArcade"] = "pcarcade";
369
+ ZRomulatorSystemId["PcEngine"] = "pcengine";
370
+ ZRomulatorSystemId["PcEngineCd"] = "pcenginecd";
371
+ ZRomulatorSystemId["PCFx"] = "pcfx";
372
+ ZRomulatorSystemId["Pico8"] = "pico8";
373
+ ZRomulatorSystemId["Plus4"] = "plus4";
374
+ ZRomulatorSystemId["PokeMini"] = "pokemini";
375
+ ZRomulatorSystemId["Ports"] = "ports";
376
+ ZRomulatorSystemId["PS2"] = "ps2";
377
+ ZRomulatorSystemId["PS3"] = "ps3";
378
+ ZRomulatorSystemId["PS4"] = "ps4";
379
+ ZRomulatorSystemId["PSP"] = "psp";
380
+ ZRomulatorSystemId["PSVita"] = "psvita";
381
+ ZRomulatorSystemId["PSX"] = "psx";
382
+ ZRomulatorSystemId["PV1000"] = "pv1000";
383
+ ZRomulatorSystemId["Quake"] = "quake";
384
+ ZRomulatorSystemId["SamCoupe"] = "samcoupe";
385
+ ZRomulatorSystemId["Satellaview"] = "satellaview";
386
+ ZRomulatorSystemId["Saturn"] = "saturn";
387
+ ZRomulatorSystemId["SaturnJp"] = "saturnjp";
388
+ ZRomulatorSystemId["ScummVM"] = "scummvm";
389
+ ZRomulatorSystemId["SCV"] = "scv";
390
+ ZRomulatorSystemId["Sega32X"] = "sega32x";
391
+ ZRomulatorSystemId["Sega32XJp"] = "sega32xjp";
392
+ ZRomulatorSystemId["Sega32XNa"] = "sega32xna";
393
+ ZRomulatorSystemId["SegaCd"] = "segacd";
394
+ ZRomulatorSystemId["SFC"] = "sfc";
395
+ ZRomulatorSystemId["Sg1000"] = "sg-1000";
396
+ ZRomulatorSystemId["SGB"] = "sgb";
397
+ ZRomulatorSystemId["SuperNintendo"] = "snes";
398
+ ZRomulatorSystemId["SnesNa"] = "snesna";
399
+ ZRomulatorSystemId["Solarus"] = "solarus";
400
+ ZRomulatorSystemId["SpectraVideo"] = "spectravideo";
401
+ ZRomulatorSystemId["Steam"] = "steam";
402
+ ZRomulatorSystemId["STV"] = "stv";
403
+ ZRomulatorSystemId["Sufami"] = "sufami";
404
+ ZRomulatorSystemId["SuperGrafx"] = "supergrafx";
405
+ ZRomulatorSystemId["SuperVision"] = "supervision";
406
+ ZRomulatorSystemId["SupraCan"] = "supracan";
407
+ ZRomulatorSystemId["Switch"] = "switch";
408
+ ZRomulatorSystemId["Symbian"] = "symbian";
409
+ ZRomulatorSystemId["TanoDragon"] = "tanodragon";
410
+ ZRomulatorSystemId["TgCd"] = "tg-cd";
411
+ ZRomulatorSystemId["TG16"] = "tg16";
412
+ ZRomulatorSystemId["TI99"] = "ti99";
413
+ ZRomulatorSystemId["TIC80"] = "tic80";
414
+ ZRomulatorSystemId["TO8"] = "to8";
415
+ ZRomulatorSystemId["Triforce"] = "triforce";
416
+ ZRomulatorSystemId["TRS80"] = "trs-80";
417
+ ZRomulatorSystemId["TypeX"] = "type-x";
418
+ ZRomulatorSystemId["Uzebox"] = "uzebox";
419
+ ZRomulatorSystemId["Vectrex"] = "vectrex";
420
+ ZRomulatorSystemId["Vic20"] = "vic20";
421
+ ZRomulatorSystemId["VideoPac"] = "videopac";
422
+ ZRomulatorSystemId["Vircon32"] = "vircon32";
423
+ ZRomulatorSystemId["VirtualBoy"] = "virtualboy";
424
+ ZRomulatorSystemId["VPinball"] = "vpinball";
425
+ ZRomulatorSystemId["VSmile"] = "vsmile";
426
+ ZRomulatorSystemId["Wasm4"] = "wasm4";
427
+ ZRomulatorSystemId["Wii"] = "wii";
428
+ ZRomulatorSystemId["WiiU"] = "wiiu";
429
+ ZRomulatorSystemId["Windows"] = "windows";
430
+ ZRomulatorSystemId["Windows3X"] = "windows3x";
431
+ ZRomulatorSystemId["Windows9X"] = "windows9x";
432
+ ZRomulatorSystemId["WonderSwan"] = "wonderswan";
433
+ ZRomulatorSystemId["WonderSwanColor"] = "wonderswancolor";
434
+ ZRomulatorSystemId["X1"] = "x1";
435
+ ZRomulatorSystemId["X68000"] = "x68000";
436
+ ZRomulatorSystemId["Xbox"] = "xbox";
437
+ ZRomulatorSystemId["Xbox360"] = "xbox360";
438
+ ZRomulatorSystemId["XboxOne"] = "xboxone";
439
+ ZRomulatorSystemId["ZMachine"] = "zmachine";
440
+ ZRomulatorSystemId["Zx81"] = "zx81";
441
+ ZRomulatorSystemId["ZxNext"] = "zxnext";
442
+ ZRomulatorSystemId["ZxSpectrum"] = "zxspectrum";
280
443
  return ZRomulatorSystemId;
281
444
  }({});
282
445
  const ZRomulatorSystemIdMap = lodashEs.keyBy(Object.values(ZRomulatorSystemId));
@@ -332,15 +495,17 @@ const ZRomulatorSystemIdMap = lodashEs.keyBy(Object.values(ZRomulatorSystemId));
332
495
  builder = builder.filename(fileName);
333
496
  const ext = node_path.extname(fileName);
334
497
  const title = node_path.basename(fileName, ext);
335
- if (isMediaType(fileName) && isSystemId(parent)) {
498
+ if (isSystemMediaType(fileName) && isSystemId(parent)) {
336
499
  // This is media for system hardware
337
500
  const id = `${parent}-${lodashEs.kebabCase(title)}`;
338
501
  return builder.id(id).system(parent).type(fileName).game(undefined);
339
502
  }
340
- if (fileName && isMediaType(parent) && isSystemId(grandparent)) {
341
- // This is media for a game that is supported.
503
+ if (fileName && isGameMediaType(parent) && isSystemId(grandparent)) {
504
+ // This is media for a game that is supported. The id for a game
505
+ // is the system id followed by the kebab case of the title, followed
506
+ // by the media type.
342
507
  const game = lodashEs.kebabCase(title);
343
- const id = `${grandparent}-${parent}-${game}`;
508
+ const id = `${grandparent}-${game}-${parent}`;
344
509
  return builder.id(id).system(grandparent).type(parent).game(game);
345
510
  }
346
511
  return builder;
@@ -355,17 +520,32 @@ const ZRomulatorSystemIdMap = lodashEs.keyBy(Object.values(ZRomulatorSystemId));
355
520
  * Describes a type of system.
356
521
  */ var ZRomulatorSystemType = /*#__PURE__*/ function(ZRomulatorSystemType) {
357
522
  /**
358
- * A console system.
359
- */ ZRomulatorSystemType["Console"] = "console";
360
- /**
361
- * A handheld system
362
- */ ZRomulatorSystemType["Handheld"] = "handheld";
523
+ * An accessory that attaches to another system.
524
+ */ ZRomulatorSystemType["Accessory"] = "accessory";
363
525
  /**
364
526
  * A cabinet system
365
527
  */ ZRomulatorSystemType["Arcade"] = "arcade";
366
528
  /**
367
529
  * Known computer systems
368
530
  */ ZRomulatorSystemType["Computer"] = "computer";
531
+ /**
532
+ * A console system.
533
+ */ ZRomulatorSystemType["Console"] = "console";
534
+ /**
535
+ * Pinball
536
+ */ ZRomulatorSystemType["Flipper"] = "flipper";
537
+ /**
538
+ * A handheld system
539
+ */ ZRomulatorSystemType["Handheld"] = "console-portable";
540
+ /**
541
+ * Script Creation Utility.
542
+ */ ZRomulatorSystemType["ScummVm"] = "scummvm";
543
+ /**
544
+ * Phone based system
545
+ */ ZRomulatorSystemType["Smartphone"] = "smartphone";
546
+ /**
547
+ * Virtual machine based system.
548
+ */ ZRomulatorSystemType["VirtualMachine"] = "virtual-machine";
369
549
  return ZRomulatorSystemType;
370
550
  }({});
371
551
 
@@ -433,32 +613,6 @@ const ZRomulatorSystemIdMap = lodashEs.keyBy(Object.values(ZRomulatorSystemId));
433
613
  * This instance.
434
614
  */ computer = this.type.bind(this, ZRomulatorSystemType.Computer);
435
615
  /**
436
- * Sets the aliases of the system.
437
- *
438
- * @param aliases -
439
- * The aliases of the system.
440
- * @returns
441
- * This instance.
442
- */ aliases(aliases) {
443
- this._system.aliases = aliases;
444
- return this;
445
- }
446
- /**
447
- * Adds an alias to the system.
448
- *
449
- * If an alias already exists, then it will
450
- * not be added again.
451
- *
452
- * @param alias -
453
- * The alias to add to the system.
454
- * @returns
455
- * This instance.
456
- */ alias(alias) {
457
- const aliases = helpfulFn.firstDefined([], this._system.aliases).slice();
458
- aliases.push(alias);
459
- return this.aliases(lodashEs.uniq(aliases));
460
- }
461
- /**
462
616
  * Sets the generational index of the system.
463
617
  *
464
618
  * @param generation -
@@ -470,29 +624,19 @@ const ZRomulatorSystemIdMap = lodashEs.keyBy(Object.values(ZRomulatorSystemId));
470
624
  return this;
471
625
  }
472
626
  /**
473
- * Sets the manufacturers of the system.
474
- *
475
- * @param manufacturers -
476
- * The manufacturers of the system.
477
- * @returns
478
- * This instance.
479
- */ manufacturers(manufacturers) {
480
- this._system.manufacturers = manufacturers;
481
- return this;
482
- }
483
- /**
484
- * Adds a manufacturer for the system.
627
+ * Assigns system data to this system.
485
628
  *
486
- * If a manufacturer already exists, then it will not be added again.
629
+ * @param system -
630
+ * The partial system data to assign.
487
631
  *
488
- * @param manufacturer -
489
- * The manufacturer of the system.
490
632
  * @returns
491
- * This instance.
492
- */ manufacturer(manufacturer) {
493
- const manufacturers = helpfulFn.firstDefined([], this._system.manufacturers).slice();
494
- manufacturers.push(manufacturer);
495
- return this.manufacturers(lodashEs.uniq(manufacturers));
633
+ * This object.
634
+ */ assign(system) {
635
+ this._system = {
636
+ ...this._system,
637
+ ...system
638
+ };
639
+ return this;
496
640
  }
497
641
  /**
498
642
  * Builds the system instance.
@@ -509,14 +653,15 @@ exports.ZRomulatorConfigBuilder = ZRomulatorConfigBuilder;
509
653
  exports.ZRomulatorConfigGamesBuilder = ZRomulatorConfigGamesBuilder;
510
654
  exports.ZRomulatorConfigGamesMetadata = ZRomulatorConfigGamesMetadata;
511
655
  exports.ZRomulatorConfigId = ZRomulatorConfigId;
512
- exports.ZRomulatorConfigMediaBuilder = ZRomulatorConfigMediaBuilder;
513
- exports.ZRomulatorConfigMediaMetadata = ZRomulatorConfigMediaMetadata;
514
656
  exports.ZRomulatorGameBuilder = ZRomulatorGameBuilder;
657
+ exports.ZRomulatorGameMediaType = ZRomulatorGameMediaType;
515
658
  exports.ZRomulatorMediaBuilder = ZRomulatorMediaBuilder;
516
- exports.ZRomulatorMediaType = ZRomulatorMediaType;
517
659
  exports.ZRomulatorSystemBuilder = ZRomulatorSystemBuilder;
518
660
  exports.ZRomulatorSystemId = ZRomulatorSystemId;
661
+ exports.ZRomulatorSystemMediaType = ZRomulatorSystemMediaType;
519
662
  exports.ZRomulatorSystemType = ZRomulatorSystemType;
663
+ exports.isGameMediaType = isGameMediaType;
520
664
  exports.isMediaType = isMediaType;
521
665
  exports.isSystemId = isSystemId;
666
+ exports.isSystemMediaType = isSystemMediaType;
522
667
  //# sourceMappingURL=index.cjs.map