@anweather/game-plugin-ssdk 1.18.0 → 1.19.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/dist-cjs/src/models/models_0.js +71 -1
- package/dist-cjs/src/protocols/Aws_restJson1.js +10 -0
- package/dist-cjs/tsconfig.cjs.tsbuildinfo +1 -1
- package/dist-es/src/models/models_0.js +70 -0
- package/dist-es/src/protocols/Aws_restJson1.js +10 -0
- package/dist-es/tsconfig.es.tsbuildinfo +1 -1
- package/dist-types/src/models/models_0.d.ts +46 -0
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ValidateMoveInput = exports.MoveValidation = exports.SelectBotMoveOutput = exports.SelectBotMoveInput = exports.IsOutOfTurnMoveOutput = exports.IsOutOfTurnMoveInput = exports.IsConfigMoveOutput = exports.IsConfigMoveInput = exports.InitializeGameInput = exports.HealthOutput = exports.GetSaveFileEditorStateOutput = exports.GetSaveFileEditorStateInput = exports.GetPlayerViewOutput = exports.GetPlayerViewInput = exports.GameTypeMetadata = exports.SpaceCapability = exports.GameStatusOutput = exports.PluginStateOnlyInput = exports.GameResultOutput = exports.Outcome = exports.DescribeSaveFileOutput = exports.DescribeSaveFileInput = exports.BotSkillLevelEntry = exports.AssignParticipantsOutput = exports.AssignParticipantsInput = exports.SaveFileEditRejectedError = exports.ApplySaveFileEditOutput = exports.ApplySaveFileEditInput = exports.PluginStateUpdate = exports.InvalidMoveError = exports.ApplyMoveInput = exports.Move = void 0;
|
|
3
|
+
exports.ValidateMoveInput = exports.MoveValidation = exports.SelectBotMoveOutput = exports.SelectBotMoveInput = exports.IsOutOfTurnMoveOutput = exports.IsOutOfTurnMoveInput = exports.IsConfigMoveOutput = exports.IsConfigMoveInput = exports.InitializeGameInput = exports.HealthOutput = exports.GetSaveFileEditorStateOutput = exports.GetSaveFileEditorStateInput = exports.GetPlayerViewOutput = exports.GetPlayerViewInput = exports.GameTypeMetadata = exports.SpaceCapability = exports.LiveCapability = exports.LiveScope = exports.LiveMode = exports.GameStatusOutput = exports.PluginStateOnlyInput = exports.GameResultOutput = exports.Outcome = exports.DescribeSaveFileOutput = exports.DescribeSaveFileInput = exports.BotSkillLevelEntry = exports.AssignParticipantsOutput = exports.AssignParticipantsInput = exports.SaveFileEditRejectedError = exports.ApplySaveFileEditOutput = exports.ApplySaveFileEditInput = exports.PluginStateUpdate = exports.InvalidMoveError = exports.ApplyMoveInput = exports.Move = void 0;
|
|
4
4
|
const server_common_1 = require("@aws-smithy/server-common");
|
|
5
5
|
var Move;
|
|
6
6
|
(function (Move) {
|
|
@@ -411,6 +411,71 @@ var GameStatusOutput;
|
|
|
411
411
|
];
|
|
412
412
|
};
|
|
413
413
|
})(GameStatusOutput || (exports.GameStatusOutput = GameStatusOutput = {}));
|
|
414
|
+
exports.LiveMode = {
|
|
415
|
+
HOSTED: "HOSTED",
|
|
416
|
+
RELAY: "RELAY",
|
|
417
|
+
};
|
|
418
|
+
exports.LiveScope = {
|
|
419
|
+
GAME: "GAME",
|
|
420
|
+
SPACE: "SPACE",
|
|
421
|
+
};
|
|
422
|
+
var LiveCapability;
|
|
423
|
+
(function (LiveCapability) {
|
|
424
|
+
const memberValidators = {};
|
|
425
|
+
LiveCapability.validate = (obj, path = "") => {
|
|
426
|
+
function getMemberValidator(member) {
|
|
427
|
+
if (memberValidators[member] === undefined) {
|
|
428
|
+
switch (member) {
|
|
429
|
+
case "mode": {
|
|
430
|
+
memberValidators["mode"] = new server_common_1.CompositeValidator([
|
|
431
|
+
new server_common_1.EnumValidator([
|
|
432
|
+
"RELAY",
|
|
433
|
+
"HOSTED",
|
|
434
|
+
], [
|
|
435
|
+
"RELAY",
|
|
436
|
+
"HOSTED",
|
|
437
|
+
]),
|
|
438
|
+
new server_common_1.RequiredValidator(),
|
|
439
|
+
]);
|
|
440
|
+
break;
|
|
441
|
+
}
|
|
442
|
+
case "scope": {
|
|
443
|
+
memberValidators["scope"] = new server_common_1.CompositeValidator([
|
|
444
|
+
new server_common_1.EnumValidator([
|
|
445
|
+
"GAME",
|
|
446
|
+
"SPACE",
|
|
447
|
+
], [
|
|
448
|
+
"GAME",
|
|
449
|
+
"SPACE",
|
|
450
|
+
]),
|
|
451
|
+
]);
|
|
452
|
+
break;
|
|
453
|
+
}
|
|
454
|
+
case "spectators": {
|
|
455
|
+
memberValidators["spectators"] = new server_common_1.NoOpValidator();
|
|
456
|
+
break;
|
|
457
|
+
}
|
|
458
|
+
case "maxSignalsPerSecond": {
|
|
459
|
+
memberValidators["maxSignalsPerSecond"] = new server_common_1.NoOpValidator();
|
|
460
|
+
break;
|
|
461
|
+
}
|
|
462
|
+
case "maxSignalBytes": {
|
|
463
|
+
memberValidators["maxSignalBytes"] = new server_common_1.NoOpValidator();
|
|
464
|
+
break;
|
|
465
|
+
}
|
|
466
|
+
}
|
|
467
|
+
}
|
|
468
|
+
return memberValidators[member];
|
|
469
|
+
}
|
|
470
|
+
return [
|
|
471
|
+
...getMemberValidator("mode").validate(obj.mode, `${path}/mode`),
|
|
472
|
+
...getMemberValidator("scope").validate(obj.scope, `${path}/scope`),
|
|
473
|
+
...getMemberValidator("spectators").validate(obj.spectators, `${path}/spectators`),
|
|
474
|
+
...getMemberValidator("maxSignalsPerSecond").validate(obj.maxSignalsPerSecond, `${path}/maxSignalsPerSecond`),
|
|
475
|
+
...getMemberValidator("maxSignalBytes").validate(obj.maxSignalBytes, `${path}/maxSignalBytes`),
|
|
476
|
+
];
|
|
477
|
+
};
|
|
478
|
+
})(LiveCapability || (exports.LiveCapability = LiveCapability = {}));
|
|
414
479
|
var SpaceCapability;
|
|
415
480
|
(function (SpaceCapability) {
|
|
416
481
|
const memberValidators = {};
|
|
@@ -531,6 +596,10 @@ var GameTypeMetadata;
|
|
|
531
596
|
memberValidators["spaces"] = new server_common_1.CompositeStructureValidator(new server_common_1.NoOpValidator(), SpaceCapability.validate);
|
|
532
597
|
break;
|
|
533
598
|
}
|
|
599
|
+
case "live": {
|
|
600
|
+
memberValidators["live"] = new server_common_1.CompositeStructureValidator(new server_common_1.NoOpValidator(), LiveCapability.validate);
|
|
601
|
+
break;
|
|
602
|
+
}
|
|
534
603
|
}
|
|
535
604
|
}
|
|
536
605
|
return memberValidators[member];
|
|
@@ -552,6 +621,7 @@ var GameTypeMetadata;
|
|
|
552
621
|
...getMemberValidator("hasSaveSummary").validate(obj.hasSaveSummary, `${path}/hasSaveSummary`),
|
|
553
622
|
...getMemberValidator("hasSaveFileEditor").validate(obj.hasSaveFileEditor, `${path}/hasSaveFileEditor`),
|
|
554
623
|
...getMemberValidator("spaces").validate(obj.spaces, `${path}/spaces`),
|
|
624
|
+
...getMemberValidator("live").validate(obj.live, `${path}/live`),
|
|
555
625
|
];
|
|
556
626
|
};
|
|
557
627
|
})(GameTypeMetadata || (exports.GameTypeMetadata = GameTypeMetadata = {}));
|
|
@@ -640,6 +640,7 @@ const serializeGetMetadataResponse = async (input, ctx) => {
|
|
|
640
640
|
'hasSaveFiles': [],
|
|
641
641
|
'hasSaveSummary': [],
|
|
642
642
|
'id': [],
|
|
643
|
+
'live': _ => se_LiveCapability(_, context),
|
|
643
644
|
'maxPlayers': [],
|
|
644
645
|
'minPlayers': [],
|
|
645
646
|
'spaces': _ => se_SpaceCapability(_, context),
|
|
@@ -1052,6 +1053,15 @@ const se_BotSkillLevelList = (input, context) => {
|
|
|
1052
1053
|
return se_BotSkillLevelEntry(entry, context);
|
|
1053
1054
|
});
|
|
1054
1055
|
};
|
|
1056
|
+
const se_LiveCapability = (input, context) => {
|
|
1057
|
+
return (0, smithy_client_1.take)(input, {
|
|
1058
|
+
'maxSignalBytes': [],
|
|
1059
|
+
'maxSignalsPerSecond': [],
|
|
1060
|
+
'mode': [],
|
|
1061
|
+
'scope': [],
|
|
1062
|
+
'spectators': [],
|
|
1063
|
+
});
|
|
1064
|
+
};
|
|
1055
1065
|
const se_ParticipantIdList = (input, context) => {
|
|
1056
1066
|
return input.filter((e) => e != null);
|
|
1057
1067
|
};
|