@gamepark/mythologies 1.0.21 → 1.0.23

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.
@@ -45,6 +45,7 @@ export class CaimanSacrificeEffectRule extends SacrificeEffectRule {
45
45
  const pantheon = new Pantheon(this.game, this.player);
46
46
  pantheon.onCardSacrificed(move.itemIndex);
47
47
  moves.push(pantheon.gainGems(1));
48
+ this.memorize(Memory.TargetEntities, (indexes) => indexes.filter((i) => i !== move.itemIndex));
48
49
  const remaining = this.memorize(Memory.EffectCount, (count) => count - 1);
49
50
  if (!remaining) {
50
51
  moves.push(this.customMove(CustomMoveType.EndEffect));
@@ -7,6 +7,7 @@ export declare class TianlongEffectRule extends MoveEffectRule {
7
7
  ruleId: RuleId;
8
8
  getPlayerMoves(): MaterialMove[];
9
9
  onCardMoved(move: MoveItem): MaterialMove[];
10
+ updateGridAfterMoves(): void;
10
11
  }
11
12
  export declare class TianlongOpponentsEffectRule extends SimultaneousMoveEffectRule {
12
13
  ruleId: RuleId;
@@ -5,6 +5,7 @@ import { MaterialType } from '../../material/MaterialType';
5
5
  import { Pantheon } from '../../material/Pantheon';
6
6
  import { Memory } from '../../Memory';
7
7
  import { RuleId } from '../RuleId';
8
+ import { TriggerEffectsRule } from './TriggerEffectsRule';
8
9
  export class TianlongEffectRule extends MoveEffectRule {
9
10
  ruleId = RuleId.TianlongEffect;
10
11
  getPlayerMoves() {
@@ -26,6 +27,11 @@ export class TianlongEffectRule extends MoveEffectRule {
26
27
  }
27
28
  return [];
28
29
  }
30
+ updateGridAfterMoves() {
31
+ for (const player of new TriggerEffectsRule(this.game).getPlayersByEffectPriorityOrder()) {
32
+ new Pantheon(this.game, player).updateGrid();
33
+ }
34
+ }
29
35
  }
30
36
  export class TianlongOpponentsEffectRule extends SimultaneousMoveEffectRule {
31
37
  ruleId = RuleId.TianlongOpponentsEffect;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gamepark/mythologies",
3
- "version": "1.0.21",
3
+ "version": "1.0.23",
4
4
  "description": "The rules of Mythologies adapted for Game Park",
5
5
  "sideEffects": false,
6
6
  "type": "module",
@@ -18,15 +18,17 @@
18
18
  "build": "tsc",
19
19
  "prepublishOnly": "tsc",
20
20
  "publish": "lerna publish",
21
+ "test": "vitest",
21
22
  "lint": "eslint --fix"
22
23
  },
23
24
  "peerDependencies": {
24
25
  "@gamepark/rules-api": ">=7",
25
- "es-toolkit": "^1.44.0"
26
+ "es-toolkit": "^1.45.1"
26
27
  },
27
28
  "devDependencies": {
28
- "@gamepark/rules-api": "~7.6.0",
29
- "es-toolkit": "^1.44.0"
29
+ "@gamepark/rules-api": "~7.6.1",
30
+ "es-toolkit": "^1.45.1",
31
+ "vitest": "^4.1.1"
30
32
  },
31
- "gitHead": "4dfc870ee99fb2e88921b077bcaaea9118999e15"
33
+ "gitHead": "4204f64aaf01c1955a0011bd0c53b8b3a834e41d"
32
34
  }