@gamepark/mythologies 0.9.1 → 0.9.2
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/Memory.d.ts +1 -1
- package/dist/Memory.js +1 -1
- package/dist/material/Entity.d.ts +2 -2
- package/dist/material/Entity.js +2 -2
- package/dist/rules/RuleId.d.ts +2 -1
- package/dist/rules/RuleId.js +1 -0
- package/dist/rules/effects/GarudaEffectRule.js +2 -2
- package/dist/rules/effects/IllapaEffectRule.js +4 -4
- package/dist/rules/effects/MinotaurEffectRule.js +3 -3
- package/package.json +2 -2
package/dist/Memory.d.ts
CHANGED
package/dist/Memory.js
CHANGED
|
@@ -13,6 +13,6 @@ var Memory;
|
|
|
13
13
|
Memory[Memory["EffectCount"] = 8] = "EffectCount";
|
|
14
14
|
Memory[Memory["EntityMoved"] = 9] = "EntityMoved";
|
|
15
15
|
Memory[Memory["TargetMythology"] = 10] = "TargetMythology";
|
|
16
|
-
Memory[Memory["
|
|
16
|
+
Memory[Memory["TargetPlane"] = 11] = "TargetPlane";
|
|
17
17
|
Memory[Memory["TargetLocations"] = 12] = "TargetLocations";
|
|
18
18
|
})(Memory = exports.Memory || (exports.Memory = {}));
|
package/dist/material/Entity.js
CHANGED
|
@@ -44,8 +44,8 @@ var Entity;
|
|
|
44
44
|
Entity[Entity["Vetala"] = 39] = "Vetala";
|
|
45
45
|
Entity[Entity["Kinnara"] = 40] = "Kinnara";
|
|
46
46
|
Entity[Entity["Viracocha"] = 41] = "Viracocha";
|
|
47
|
-
Entity[Entity["
|
|
48
|
-
Entity[Entity["
|
|
47
|
+
Entity[Entity["MamaQucha"] = 42] = "MamaQucha";
|
|
48
|
+
Entity[Entity["Illapa"] = 43] = "Illapa";
|
|
49
49
|
Entity[Entity["Inti"] = 44] = "Inti";
|
|
50
50
|
Entity[Entity["Puma"] = 45] = "Puma";
|
|
51
51
|
Entity[Entity["Amaru"] = 46] = "Amaru";
|
package/dist/rules/RuleId.d.ts
CHANGED
package/dist/rules/RuleId.js
CHANGED
|
@@ -65,4 +65,5 @@ var RuleId;
|
|
|
65
65
|
RuleId[RuleId["Mythology"] = 1000] = "Mythology";
|
|
66
66
|
RuleId[RuleId["Creature"] = 1001] = "Creature";
|
|
67
67
|
RuleId[RuleId["Divinity"] = 1002] = "Divinity";
|
|
68
|
+
RuleId[RuleId["Destined"] = 1003] = "Destined";
|
|
68
69
|
})(RuleId = exports.RuleId || (exports.RuleId = {}));
|
|
@@ -62,7 +62,7 @@ var GarudaEffectRule = (function (_super) {
|
|
|
62
62
|
};
|
|
63
63
|
GarudaEffectRule.prototype.onCustomMove = function (move) {
|
|
64
64
|
if (move.type === CustomMoveType_1.CustomMoveType.ChoosePlan) {
|
|
65
|
-
this.memorize(Memory_1.Memory.
|
|
65
|
+
this.memorize(Memory_1.Memory.TargetPlane, move.data);
|
|
66
66
|
return [this.startRule(RuleId_1.RuleId.GarudaSacrifice)];
|
|
67
67
|
}
|
|
68
68
|
return _super.prototype.onCustomMove.call(this, move);
|
|
@@ -91,7 +91,7 @@ var GarudaSacrificeRule = (function (_super) {
|
|
|
91
91
|
};
|
|
92
92
|
GarudaSacrificeRule.prototype.getCardsToSacrifice = function () {
|
|
93
93
|
var pantheon = new Pantheon_1.Pantheon(this.game, this.player);
|
|
94
|
-
var plan = this.remind(Memory_1.Memory.
|
|
94
|
+
var plan = this.remind(Memory_1.Memory.TargetPlane);
|
|
95
95
|
return pantheon.visibleEntities.id(function (id) { return (0, Entity_1.isCreature)(id.front); }).location(function (l) { return l.y === plan; });
|
|
96
96
|
};
|
|
97
97
|
GarudaSacrificeRule.prototype.onSacrifice = function () {
|
|
@@ -37,10 +37,10 @@ var IllapaEffectRule = (function (_super) {
|
|
|
37
37
|
};
|
|
38
38
|
IllapaEffectRule.prototype.onCustomMove = function (move) {
|
|
39
39
|
if (move.type === CustomMoveType_1.CustomMoveType.ChoosePlan) {
|
|
40
|
-
this.memorize(Memory_1.Memory.
|
|
40
|
+
this.memorize(Memory_1.Memory.TargetPlane, move.data);
|
|
41
41
|
var moves = new IllapaSacrificeRule(this.game).playEffect();
|
|
42
42
|
if (!moves.some(rules_api_1.isStartSimultaneousRule)) {
|
|
43
|
-
this.forget(Memory_1.Memory.
|
|
43
|
+
this.forget(Memory_1.Memory.TargetPlane);
|
|
44
44
|
moves.push(this.customMove(CustomMoveType_1.CustomMoveType.EndEffect));
|
|
45
45
|
}
|
|
46
46
|
return moves;
|
|
@@ -62,13 +62,13 @@ var IllapaSacrificeRule = (function (_super) {
|
|
|
62
62
|
return this.game.players.filter(function (player) { return _this.isOpponent(player); });
|
|
63
63
|
};
|
|
64
64
|
IllapaSacrificeRule.prototype.getCardsToSacrifice = function (player) {
|
|
65
|
-
var line = this.remind(Memory_1.Memory.
|
|
65
|
+
var line = this.remind(Memory_1.Memory.TargetPlane);
|
|
66
66
|
return _super.prototype.getCardsToSacrifice.call(this, player)
|
|
67
67
|
.id(function (id) { return (0, Entity_1.isCreature)(id.front); })
|
|
68
68
|
.location(function (l) { return l.y === line; });
|
|
69
69
|
};
|
|
70
70
|
IllapaSacrificeRule.prototype.onRuleEnd = function () {
|
|
71
|
-
this.forget(Memory_1.Memory.
|
|
71
|
+
this.forget(Memory_1.Memory.TargetPlane);
|
|
72
72
|
return [];
|
|
73
73
|
};
|
|
74
74
|
return IllapaSacrificeRule;
|
|
@@ -29,19 +29,19 @@ var MinotaurEffectRule = (function (_super) {
|
|
|
29
29
|
return _this;
|
|
30
30
|
}
|
|
31
31
|
MinotaurEffectRule.prototype.onRuleStart = function () {
|
|
32
|
-
this.memorize(Memory_1.Memory.
|
|
32
|
+
this.memorize(Memory_1.Memory.TargetPlane, this.card.location.x);
|
|
33
33
|
return _super.prototype.onRuleStart.call(this);
|
|
34
34
|
};
|
|
35
35
|
MinotaurEffectRule.prototype.getMovingCards = function (player) {
|
|
36
36
|
var _a;
|
|
37
|
-
var column = (_a = this.remind(Memory_1.Memory.
|
|
37
|
+
var column = (_a = this.remind(Memory_1.Memory.TargetPlane)) !== null && _a !== void 0 ? _a : this.card.location.x;
|
|
38
38
|
return new Pantheon_1.Pantheon(this.game, player).visibleEntities.location(function (l) { return l.x === column; }).id(function (id) { return (0, Entity_1.isCreature)(id.front); });
|
|
39
39
|
};
|
|
40
40
|
MinotaurEffectRule.prototype.isLegalDestination = function (space, cardLocation) {
|
|
41
41
|
return space.y === cardLocation.y;
|
|
42
42
|
};
|
|
43
43
|
MinotaurEffectRule.prototype.onRuleEnd = function () {
|
|
44
|
-
this.forget(Memory_1.Memory.
|
|
44
|
+
this.forget(Memory_1.Memory.TargetPlane);
|
|
45
45
|
return [];
|
|
46
46
|
};
|
|
47
47
|
return MinotaurEffectRule;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gamepark/mythologies",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.2",
|
|
4
4
|
"description": "The rules of Mythologies adapted for Game Park",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -29,5 +29,5 @@
|
|
|
29
29
|
"i18next": "^22.0.3",
|
|
30
30
|
"lodash": "^4.17.21"
|
|
31
31
|
},
|
|
32
|
-
"gitHead": "
|
|
32
|
+
"gitHead": "5ced6a4b41d759e4af00a06e973df4d6a13c2134"
|
|
33
33
|
}
|