@firestone-hs/simulate-bgs-battle 1.1.487 → 1.1.488
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/bgs-player-entity.d.ts +2 -1
- package/dist/bgs-player-entity.js.map +1 -1
- package/dist/cards/card.interface.d.ts +12 -0
- package/dist/cards/card.interface.js +3 -0
- package/dist/cards/card.interface.js.map +1 -0
- package/dist/cards/cards-data.js +6 -0
- package/dist/cards/cards-data.js.map +1 -1
- package/dist/cards/impl/anomaly/anomalous-twin.d.ts +8 -0
- package/dist/cards/impl/anomaly/anomalous-twin.js +24 -0
- package/dist/cards/impl/anomaly/anomalous-twin.js.map +1 -0
- package/dist/cards/impl/anomaly/blessed-or-blighted.d.ts +5 -0
- package/dist/cards/impl/anomaly/blessed-or-blighted.js +16 -0
- package/dist/cards/impl/anomaly/blessed-or-blighted.js.map +1 -0
- package/dist/cards/impl/hero-power/aim-high.d.ts +5 -0
- package/dist/cards/impl/hero-power/aim-high.js +18 -0
- package/dist/cards/impl/hero-power/aim-high.js.map +1 -0
- package/dist/cards/impl/hero-power/aim-left.d.ts +5 -0
- package/dist/cards/impl/hero-power/aim-left.js +16 -0
- package/dist/cards/impl/hero-power/aim-left.js.map +1 -0
- package/dist/cards/impl/hero-power/aim-low.d.ts +5 -0
- package/dist/cards/impl/hero-power/aim-low.js +18 -0
- package/dist/cards/impl/hero-power/aim-low.js.map +1 -0
- package/dist/cards/impl/hero-power/aim-right.d.ts +5 -0
- package/dist/cards/impl/hero-power/aim-right.js +16 -0
- package/dist/cards/impl/hero-power/aim-right.js.map +1 -0
- package/dist/cards/impl/hero-power/all-will-burn.d.ts +5 -0
- package/dist/cards/impl/hero-power/all-will-burn.js +18 -0
- package/dist/cards/impl/hero-power/all-will-burn.js.map +1 -0
- package/dist/cards/impl/hero-power/earth-invocation.d.ts +5 -0
- package/dist/cards/impl/hero-power/earth-invocation.js +13 -0
- package/dist/cards/impl/hero-power/earth-invocation.js.map +1 -0
- package/dist/cards/impl/hero-power/embrace-your-rage.d.ts +8 -0
- package/dist/cards/impl/hero-power/embrace-your-rage.js +26 -0
- package/dist/cards/impl/hero-power/embrace-your-rage.js.map +1 -0
- package/dist/cards/impl/hero-power/fire-invocation.d.ts +5 -0
- package/dist/cards/impl/hero-power/fire-invocation.js +13 -0
- package/dist/cards/impl/hero-power/fire-invocation.js.map +1 -0
- package/dist/cards/impl/hero-power/fragrant-phylactery.d.ts +8 -0
- package/dist/cards/impl/hero-power/fragrant-phylactery.js +25 -0
- package/dist/cards/impl/hero-power/fragrant-phylactery.js.map +1 -0
- package/dist/cards/impl/hero-power/glorious-gloop.d.ts +5 -0
- package/dist/cards/impl/hero-power/glorious-gloop.js +40 -0
- package/dist/cards/impl/hero-power/glorious-gloop.js.map +1 -0
- package/dist/cards/impl/hero-power/lightning-invocation.d.ts +5 -0
- package/dist/cards/impl/hero-power/lightning-invocation.js +13 -0
- package/dist/cards/impl/hero-power/lightning-invocation.js.map +1 -0
- package/dist/cards/impl/hero-power/rapid-reanimation.d.ts +8 -0
- package/dist/cards/impl/hero-power/rapid-reanimation.js +29 -0
- package/dist/cards/impl/hero-power/rapid-reanimation.js.map +1 -0
- package/dist/cards/impl/hero-power/reborn-rites.d.ts +5 -0
- package/dist/cards/impl/hero-power/reborn-rites.js +18 -0
- package/dist/cards/impl/hero-power/reborn-rites.js.map +1 -0
- package/dist/cards/impl/hero-power/swatting-insects.d.ts +5 -0
- package/dist/cards/impl/hero-power/swatting-insects.js +21 -0
- package/dist/cards/impl/hero-power/swatting-insects.js.map +1 -0
- package/dist/cards/impl/hero-power/tentacular.d.ts +8 -0
- package/dist/cards/impl/hero-power/tentacular.js +10 -0
- package/dist/cards/impl/hero-power/tentacular.js.map +1 -0
- package/dist/cards/impl/hero-power/water-invocation.d.ts +5 -0
- package/dist/cards/impl/hero-power/water-invocation.js +13 -0
- package/dist/cards/impl/hero-power/water-invocation.js.map +1 -0
- package/dist/cards/impl/hero-power/wax-warband.d.ts +5 -0
- package/dist/cards/impl/hero-power/wax-warband.js +56 -0
- package/dist/cards/impl/hero-power/wax-warband.js.map +1 -0
- package/dist/cards/impl/minion/amber-guardian.d.ts +5 -0
- package/dist/cards/impl/minion/amber-guardian.js +31 -0
- package/dist/cards/impl/minion/amber-guardian.js.map +1 -0
- package/dist/cards/impl/minion/audacious-anchor.d.ts +5 -0
- package/dist/cards/impl/minion/audacious-anchor.js +25 -0
- package/dist/cards/impl/minion/audacious-anchor.js.map +1 -0
- package/dist/cards/impl/minion/carbonic-copy.d.ts +5 -0
- package/dist/cards/impl/minion/carbonic-copy.js +24 -0
- package/dist/cards/impl/minion/carbonic-copy.js.map +1 -0
- package/dist/cards/impl/minion/choral-mrrrglr.d.ts +5 -0
- package/dist/cards/impl/minion/choral-mrrrglr.js +14 -0
- package/dist/cards/impl/minion/choral-mrrrglr.js.map +1 -0
- package/dist/cards/impl/minion/corrupted-myrmidon.d.ts +5 -0
- package/dist/cards/impl/minion/corrupted-myrmidon.js +13 -0
- package/dist/cards/impl/minion/corrupted-myrmidon.js.map +1 -0
- package/dist/cards/impl/minion/crabby.d.ts +5 -0
- package/dist/cards/impl/minion/crabby.js +18 -0
- package/dist/cards/impl/minion/crabby.js.map +1 -0
- package/dist/cards/impl/minion/diremuck-forager.d.ts +5 -0
- package/dist/cards/impl/minion/diremuck-forager.js +32 -0
- package/dist/cards/impl/minion/diremuck-forager.js.map +1 -0
- package/dist/cards/impl/minion/elder-taggawag.d.ts +5 -0
- package/dist/cards/impl/minion/elder-taggawag.js +19 -0
- package/dist/cards/impl/minion/elder-taggawag.js.map +1 -0
- package/dist/cards/impl/minion/hawkstrider-herald.d.ts +5 -0
- package/dist/cards/impl/minion/hawkstrider-herald.js +27 -0
- package/dist/cards/impl/minion/hawkstrider-herald.js.map +1 -0
- package/dist/cards/impl/minion/hoarding-hatespawn.d.ts +5 -0
- package/dist/cards/impl/minion/hoarding-hatespawn.js +22 -0
- package/dist/cards/impl/minion/hoarding-hatespawn.js.map +1 -0
- package/dist/cards/impl/minion/humming-bird.d.ts +5 -0
- package/dist/cards/impl/minion/humming-bird.js +15 -0
- package/dist/cards/impl/minion/humming-bird.js.map +1 -0
- package/dist/cards/impl/minion/interrogator-whitemane.d.ts +5 -0
- package/dist/cards/impl/minion/interrogator-whitemane.js +33 -0
- package/dist/cards/impl/minion/interrogator-whitemane.js.map +1 -0
- package/dist/cards/impl/minion/irate-rooster.d.ts +5 -0
- package/dist/cards/impl/minion/irate-rooster.js +20 -0
- package/dist/cards/impl/minion/irate-rooster.js.map +1 -0
- package/dist/cards/impl/minion/mantid-queen.d.ts +5 -0
- package/dist/cards/impl/minion/mantid-queen.js +52 -0
- package/dist/cards/impl/minion/mantid-queen.js.map +1 -0
- package/dist/cards/impl/minion/misfit-dragonling.d.ts +5 -0
- package/dist/cards/impl/minion/misfit-dragonling.js +15 -0
- package/dist/cards/impl/minion/misfit-dragonling.js.map +1 -0
- package/dist/cards/impl/minion/piloted-whirl-o-tron.d.ts +5 -0
- package/dist/cards/impl/minion/piloted-whirl-o-tron.js +13 -0
- package/dist/cards/impl/minion/piloted-whirl-o-tron.js.map +1 -0
- package/dist/cards/impl/minion/prized-promo-drake.d.ts +5 -0
- package/dist/cards/impl/minion/prized-promo-drake.js +22 -0
- package/dist/cards/impl/minion/prized-promo-drake.js.map +1 -0
- package/dist/cards/impl/minion/red-whelp.d.ts +5 -0
- package/dist/cards/impl/minion/red-whelp.js +17 -0
- package/dist/cards/impl/minion/red-whelp.js.map +1 -0
- package/dist/cards/impl/minion/sanctum-rester.d.ts +5 -0
- package/dist/cards/impl/minion/sanctum-rester.js +20 -0
- package/dist/cards/impl/minion/sanctum-rester.js.map +1 -0
- package/dist/cards/impl/minion/sandy.d.ts +5 -0
- package/dist/cards/impl/minion/sandy.js +23 -0
- package/dist/cards/impl/minion/sandy.js.map +1 -0
- package/dist/cards/impl/minion/sky-pirate-flagbearer.d.ts +5 -0
- package/dist/cards/impl/minion/sky-pirate-flagbearer.js +24 -0
- package/dist/cards/impl/minion/sky-pirate-flagbearer.js.map +1 -0
- package/dist/cards/impl/minion/soulsplitter.d.ts +5 -0
- package/dist/cards/impl/minion/soulsplitter.js +23 -0
- package/dist/cards/impl/minion/soulsplitter.js.map +1 -0
- package/dist/cards/impl/minion/sun-screener.d.ts +5 -0
- package/dist/cards/impl/minion/sun-screener.js +15 -0
- package/dist/cards/impl/minion/sun-screener.js.map +1 -0
- package/dist/cards/impl/minion/the-uninvited-guest.d.ts +5 -0
- package/dist/cards/impl/minion/the-uninvited-guest.js +24 -0
- package/dist/cards/impl/minion/the-uninvited-guest.js.map +1 -0
- package/dist/cards/impl/minion/thousandth-paper-drake.d.ts +5 -0
- package/dist/cards/impl/minion/thousandth-paper-drake.js +24 -0
- package/dist/cards/impl/minion/thousandth-paper-drake.js.map +1 -0
- package/dist/cards/impl/minion/vaelastrasz.d.ts +5 -0
- package/dist/cards/impl/minion/vaelastrasz.js +17 -0
- package/dist/cards/impl/minion/vaelastrasz.js.map +1 -0
- package/dist/cards/impl/minion/yulon-fortune-granter.d.ts +5 -0
- package/dist/cards/impl/minion/yulon-fortune-granter.js +26 -0
- package/dist/cards/impl/minion/yulon-fortune-granter.js.map +1 -0
- package/dist/cards/impl/quest-reward/evil-twin.d.ts +5 -0
- package/dist/cards/impl/quest-reward/evil-twin.js +32 -0
- package/dist/cards/impl/quest-reward/evil-twin.js.map +1 -0
- package/dist/cards/impl/quest-reward/staff-of-origination.d.ts +5 -0
- package/dist/cards/impl/quest-reward/staff-of-origination.js +14 -0
- package/dist/cards/impl/quest-reward/staff-of-origination.js.map +1 -0
- package/dist/cards/impl/quest-reward/stolen-gold.d.ts +5 -0
- package/dist/cards/impl/quest-reward/stolen-gold.js +16 -0
- package/dist/cards/impl/quest-reward/stolen-gold.js.map +1 -0
- package/dist/cards/impl/trinket/artisanal-urn.d.ts +5 -0
- package/dist/cards/impl/trinket/artisanal-urn.js +13 -0
- package/dist/cards/impl/trinket/artisanal-urn.js.map +1 -0
- package/dist/cards/impl/trinket/automaton-portrait.d.ts +5 -0
- package/dist/cards/impl/trinket/automaton-portrait.js +15 -0
- package/dist/cards/impl/trinket/automaton-portrait.js.map +1 -0
- package/dist/cards/impl/trinket/bronze-timepiece.d.ts +5 -0
- package/dist/cards/impl/trinket/bronze-timepiece.js +17 -0
- package/dist/cards/impl/trinket/bronze-timepiece.js.map +1 -0
- package/dist/cards/impl/trinket/emerald-dreamcatcher.d.ts +5 -0
- package/dist/cards/impl/trinket/emerald-dreamcatcher.js +18 -0
- package/dist/cards/impl/trinket/emerald-dreamcatcher.js.map +1 -0
- package/dist/cards/impl/trinket/eternal-portrait.d.ts +5 -0
- package/dist/cards/impl/trinket/eternal-portrait.js +19 -0
- package/dist/cards/impl/trinket/eternal-portrait.js.map +1 -0
- package/dist/cards/impl/trinket/fishy-sticker.d.ts +5 -0
- package/dist/cards/impl/trinket/fishy-sticker.js +28 -0
- package/dist/cards/impl/trinket/fishy-sticker.js.map +1 -0
- package/dist/cards/impl/trinket/hoggy-bank.d.ts +5 -0
- package/dist/cards/impl/trinket/hoggy-bank.js +23 -0
- package/dist/cards/impl/trinket/hoggy-bank.js.map +1 -0
- package/dist/cards/impl/trinket/holly-mallet.d.ts +5 -0
- package/dist/cards/impl/trinket/holly-mallet.js +18 -0
- package/dist/cards/impl/trinket/holly-mallet.js.map +1 -0
- package/dist/cards/impl/trinket/ironforge-anvil.d.ts +5 -0
- package/dist/cards/impl/trinket/ironforge-anvil.js +23 -0
- package/dist/cards/impl/trinket/ironforge-anvil.js.map +1 -0
- package/dist/cards/impl/trinket/jarred-frostling.d.ts +5 -0
- package/dist/cards/impl/trinket/jarred-frostling.js +27 -0
- package/dist/cards/impl/trinket/jarred-frostling.js.map +1 -0
- package/dist/cards/impl/trinket/karazhan-chess-set.d.ts +5 -0
- package/dist/cards/impl/trinket/karazhan-chess-set.js +40 -0
- package/dist/cards/impl/trinket/karazhan-chess-set.js.map +1 -0
- package/dist/cards/impl/trinket/rivendare-portrait.d.ts +5 -0
- package/dist/cards/impl/trinket/rivendare-portrait.js +21 -0
- package/dist/cards/impl/trinket/rivendare-portrait.js.map +1 -0
- package/dist/cards/impl/trinket/rusty-trident.d.ts +5 -0
- package/dist/cards/impl/trinket/rusty-trident.js +23 -0
- package/dist/cards/impl/trinket/rusty-trident.js.map +1 -0
- package/dist/cards/impl/trinket/ship-in-a-bottle.d.ts +5 -0
- package/dist/cards/impl/trinket/ship-in-a-bottle.js +20 -0
- package/dist/cards/impl/trinket/ship-in-a-bottle.js.map +1 -0
- package/dist/cards/impl/trinket/summoning-sphere.d.ts +5 -0
- package/dist/cards/impl/trinket/summoning-sphere.js +31 -0
- package/dist/cards/impl/trinket/summoning-sphere.js.map +1 -0
- package/dist/cards/impl/trinket/tinyfin-onesie.d.ts +5 -0
- package/dist/cards/impl/trinket/tinyfin-onesie.js +15 -0
- package/dist/cards/impl/trinket/tinyfin-onesie.js.map +1 -0
- package/dist/cards/impl/trinket/training-certificate.d.ts +5 -0
- package/dist/cards/impl/trinket/training-certificate.js +21 -0
- package/dist/cards/impl/trinket/training-certificate.js.map +1 -0
- package/dist/cards/impl/trinket/valorous-medaillion.d.ts +5 -0
- package/dist/cards/impl/trinket/valorous-medaillion.js +12 -0
- package/dist/cards/impl/trinket/valorous-medaillion.js.map +1 -0
- package/dist/simulation/add-minion-to-board.js +18 -23
- package/dist/simulation/add-minion-to-board.js.map +1 -1
- package/dist/simulation/auras.js +0 -2
- package/dist/simulation/auras.js.map +1 -1
- package/dist/simulation/avenge.js +24 -4
- package/dist/simulation/avenge.js.map +1 -1
- package/dist/simulation/battlecries.js +9 -0
- package/dist/simulation/battlecries.js.map +1 -1
- package/dist/simulation/blood-gems.js +8 -0
- package/dist/simulation/blood-gems.js.map +1 -1
- package/dist/simulation/deathrattle-effects.js +7 -1
- package/dist/simulation/deathrattle-effects.js.map +1 -1
- package/dist/simulation/deathrattle-on-trigger.js +5 -0
- package/dist/simulation/deathrattle-on-trigger.js.map +1 -1
- package/dist/simulation/discover.js +6 -0
- package/dist/simulation/discover.js.map +1 -1
- package/dist/simulation/magnetize.js +2 -1
- package/dist/simulation/magnetize.js.map +1 -1
- package/dist/simulation/remove-minion-from-board.js +0 -10
- package/dist/simulation/remove-minion-from-board.js.map +1 -1
- package/dist/simulation/simulator.js +1 -1
- package/dist/simulation/simulator.js.map +1 -1
- package/dist/simulation/start-of-combat/phases.d.ts +1 -0
- package/dist/simulation/start-of-combat/phases.js +3 -0
- package/dist/simulation/start-of-combat/phases.js.map +1 -0
- package/dist/simulation/start-of-combat/soc-action-processor.d.ts +4 -0
- package/dist/simulation/start-of-combat/soc-action-processor.js +286 -0
- package/dist/simulation/start-of-combat/soc-action-processor.js.map +1 -0
- package/dist/simulation/start-of-combat/soc-anomalies.d.ts +4 -0
- package/dist/simulation/start-of-combat/soc-anomalies.js +39 -0
- package/dist/simulation/start-of-combat/soc-anomalies.js.map +1 -0
- package/dist/simulation/start-of-combat/soc-hero-power.d.ts +5 -0
- package/dist/simulation/start-of-combat/soc-hero-power.js +77 -0
- package/dist/simulation/start-of-combat/soc-hero-power.js.map +1 -0
- package/dist/simulation/start-of-combat/soc-illidan-hero-power.d.ts +4 -0
- package/dist/simulation/start-of-combat/soc-illidan-hero-power.js +55 -0
- package/dist/simulation/start-of-combat/soc-illidan-hero-power.js.map +1 -0
- package/dist/simulation/start-of-combat/soc-minion.d.ts +6 -0
- package/dist/simulation/start-of-combat/soc-minion.js +68 -0
- package/dist/simulation/start-of-combat/soc-minion.js.map +1 -0
- package/dist/simulation/start-of-combat/soc-pre-combat-hero-power.d.ts +4 -0
- package/dist/simulation/start-of-combat/soc-pre-combat-hero-power.js +72 -0
- package/dist/simulation/start-of-combat/soc-pre-combat-hero-power.js.map +1 -0
- package/dist/simulation/start-of-combat/soc-quest-reward.d.ts +4 -0
- package/dist/simulation/start-of-combat/soc-quest-reward.js +60 -0
- package/dist/simulation/start-of-combat/soc-quest-reward.js.map +1 -0
- package/dist/simulation/start-of-combat/soc-secret.d.ts +4 -0
- package/dist/simulation/start-of-combat/soc-secret.js +54 -0
- package/dist/simulation/start-of-combat/soc-secret.js.map +1 -0
- package/dist/simulation/start-of-combat/soc-trinket.d.ts +4 -0
- package/dist/simulation/start-of-combat/soc-trinket.js +60 -0
- package/dist/simulation/start-of-combat/soc-trinket.js.map +1 -0
- package/dist/simulation/start-of-combat/start-of-combat-input.d.ts +14 -0
- package/dist/simulation/start-of-combat/start-of-combat-input.js +3 -0
- package/dist/simulation/start-of-combat/start-of-combat-input.js.map +1 -0
- package/dist/simulation/start-of-combat/start-of-combat.d.ts +4 -0
- package/dist/simulation/start-of-combat/start-of-combat.js +68 -0
- package/dist/simulation/start-of-combat/start-of-combat.js.map +1 -0
- package/dist/temp-card-ids.d.ts +2 -0
- package/dist/temp-card-ids.js +3 -0
- package/dist/temp-card-ids.js.map +1 -0
- package/package.json +3 -3
- package/dist/simulation/start-of-combat.d.ts +0 -8
- package/dist/simulation/start-of-combat.js +0 -1187
- package/dist/simulation/start-of-combat.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"soulsplitter.js","sourceRoot":"","sources":["../../../../src/cards/impl/minion/soulsplitter.ts"],"names":[],"mappings":";;;AAAA,iEAA6D;AAE7D,mDAAqD;AAErD,0CAAiD;AAEpC,QAAA,YAAY,GAAG;IAC3B,aAAa,EAAE,CAAC,MAAmB,EAAE,KAAe,EAAE,EAAE;QACvD,MAAM,eAAe,GAAG,MAAM,CAAC,MAAM,iBAAoC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAClF,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,eAAe,EAAE,CAAC,EAAE,EAAE;YACzC,MAAM,oBAAoB,GAAG,KAAK,CAAC,WAAW;iBAC5C,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAA,uBAAe,EAAC,CAAC,EAAE,KAAK,CAAC,YAAY,EAAE,qBAAI,CAAC,MAAM,EAAE,KAAK,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;iBAC5F,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;YAC3B,MAAM,YAAY,GAAG,IAAA,kBAAU,EAAC,oBAAoB,CAAC,CAAC;YACtD,IAAI,YAAY,EAAE;gBACjB,YAAY,CAAC,MAAM,GAAG,IAAI,CAAC;gBAC3B,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,mBAAmB,CAC5C,MAAM,EACN,YAAY,EACZ,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,cAAc,CACpB,CAAC;aACF;SACD;QACD,OAAO,IAAI,CAAC;IACb,CAAC;CACD,CAAC","sourcesContent":["import { CardIds, Race } from '@firestone-hs/reference-data';\r\nimport { BoardEntity } from '../../../board-entity';\r\nimport { pickRandom } from '../../../services/utils';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\nimport { hasCorrectTribe } from '../../../utils';\r\n\r\nexport const Soulsplitter = {\r\n\tstartOfCombat: (minion: BoardEntity, input: SoCInput) => {\r\n\t\tconst numberOfTargets = minion.cardId === CardIds.Soulsplitter_BG25_023_G ? 2 : 1;\r\n\t\tfor (let i = 0; i < numberOfTargets; i++) {\r\n\t\t\tconst undeadsWithoutReborn = input.playerBoard\r\n\t\t\t\t.filter((e) => hasCorrectTribe(e, input.playerEntity, Race.UNDEAD, input.gameState.allCards))\r\n\t\t\t\t.filter((e) => !e.reborn);\r\n\t\t\tconst chosenUndead = pickRandom(undeadsWithoutReborn);\r\n\t\t\tif (chosenUndead) {\r\n\t\t\t\tchosenUndead.reborn = true;\r\n\t\t\t\tinput.gameState.spectator.registerPowerTarget(\r\n\t\t\t\t\tminion,\r\n\t\t\t\t\tchosenUndead,\r\n\t\t\t\t\tinput.playerBoard,\r\n\t\t\t\t\tinput.playerEntity,\r\n\t\t\t\t\tinput.opponentEntity,\r\n\t\t\t\t);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SunScreener = void 0;
|
|
4
|
+
const divine_shield_1 = require("../../../divine-shield");
|
|
5
|
+
exports.SunScreener = {
|
|
6
|
+
startOfCombat: (minion, input) => {
|
|
7
|
+
if (input.playerBoard.length > 0 || input.opponentBoard.length > 0) {
|
|
8
|
+
const quantity = minion.cardId === "BG30_101" ? 3 : 6;
|
|
9
|
+
(0, divine_shield_1.grantDivineShieldToLeftmostMinions)(minion, input.playerBoard, input.playerEntity, quantity, input.opponentEntity, input.gameState);
|
|
10
|
+
(0, divine_shield_1.grantDivineShieldToLeftmostMinions)(minion, input.opponentBoard, input.opponentEntity, quantity, input.playerEntity, input.gameState);
|
|
11
|
+
}
|
|
12
|
+
return true;
|
|
13
|
+
},
|
|
14
|
+
};
|
|
15
|
+
//# sourceMappingURL=sun-screener.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sun-screener.js","sourceRoot":"","sources":["../../../../src/cards/impl/minion/sun-screener.ts"],"names":[],"mappings":";;;AAEA,0DAA4E;AAG/D,QAAA,WAAW,GAAG;IAC1B,aAAa,EAAE,CAAC,MAAmB,EAAE,KAAe,EAAE,EAAE;QACvD,IAAI,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,IAAI,KAAK,CAAC,aAAa,CAAC,MAAM,GAAG,CAAC,EAAE;YACnE,MAAM,QAAQ,GAAG,MAAM,CAAC,MAAM,eAAiC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;YACxE,IAAA,kDAAkC,EACjC,MAAM,EACN,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,QAAQ,EACR,KAAK,CAAC,cAAc,EACpB,KAAK,CAAC,SAAS,CACf,CAAC;YACF,IAAA,kDAAkC,EACjC,MAAM,EACN,KAAK,CAAC,aAAa,EACnB,KAAK,CAAC,cAAc,EACpB,QAAQ,EACR,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,SAAS,CACf,CAAC;SACF;QACD,OAAO,IAAI,CAAC;IACb,CAAC;CACD,CAAC","sourcesContent":["import { CardIds } from '@firestone-hs/reference-data';\r\nimport { BoardEntity } from '../../../board-entity';\r\nimport { grantDivineShieldToLeftmostMinions } from '../../../divine-shield';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\n\r\nexport const SunScreener = {\r\n\tstartOfCombat: (minion: BoardEntity, input: SoCInput) => {\r\n\t\tif (input.playerBoard.length > 0 || input.opponentBoard.length > 0) {\r\n\t\t\tconst quantity = minion.cardId === CardIds.SunScreener_BG30_101 ? 3 : 6;\r\n\t\t\tgrantDivineShieldToLeftmostMinions(\r\n\t\t\t\tminion,\r\n\t\t\t\tinput.playerBoard,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tquantity,\r\n\t\t\t\tinput.opponentEntity,\r\n\t\t\t\tinput.gameState,\r\n\t\t\t);\r\n\t\t\tgrantDivineShieldToLeftmostMinions(\r\n\t\t\t\tminion,\r\n\t\t\t\tinput.opponentBoard,\r\n\t\t\t\tinput.opponentEntity,\r\n\t\t\t\tquantity,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tinput.gameState,\r\n\t\t\t);\r\n\t\t}\r\n\t\treturn true;\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TheUninvitedGuest = void 0;
|
|
4
|
+
exports.TheUninvitedGuest = {
|
|
5
|
+
startOfCombat: (minion, input) => {
|
|
6
|
+
const targetEnchantment = minion.cardId === "BG29_875_G"
|
|
7
|
+
? "BG29_875_Ge"
|
|
8
|
+
: "BG29_875e";
|
|
9
|
+
input.playerBoard
|
|
10
|
+
.filter((e) => e.entityId != minion.entityId)
|
|
11
|
+
.forEach((e) => {
|
|
12
|
+
e.enchantments = e.enchantments || [];
|
|
13
|
+
if (!e.enchantments.some((e) => e.cardId === targetEnchantment)) {
|
|
14
|
+
e.enchantments.push({
|
|
15
|
+
cardId: targetEnchantment,
|
|
16
|
+
originEntityId: minion.entityId,
|
|
17
|
+
timing: input.gameState.sharedState.currentEntityId++,
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
});
|
|
21
|
+
return true;
|
|
22
|
+
},
|
|
23
|
+
};
|
|
24
|
+
//# sourceMappingURL=the-uninvited-guest.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"the-uninvited-guest.js","sourceRoot":"","sources":["../../../../src/cards/impl/minion/the-uninvited-guest.ts"],"names":[],"mappings":";;;AAIa,QAAA,iBAAiB,GAAG;IAChC,aAAa,EAAE,CAAC,MAAmB,EAAE,KAAe,EAAE,EAAE;QACvD,MAAM,iBAAiB,GACtB,MAAM,CAAC,MAAM,iBAAyC;YACrD,CAAC;YACD,CAAC,YAAyD,CAAC;QAC7D,KAAK,CAAC,WAAW;aACf,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,IAAI,MAAM,CAAC,QAAQ,CAAC;aAC5C,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE;YACd,CAAC,CAAC,YAAY,GAAG,CAAC,CAAC,YAAY,IAAI,EAAE,CAAC;YACtC,IAAI,CAAC,CAAC,CAAC,YAAY,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,iBAAiB,CAAC,EAAE;gBAChE,CAAC,CAAC,YAAY,CAAC,IAAI,CAAC;oBACnB,MAAM,EAAE,iBAAiB;oBACzB,cAAc,EAAE,MAAM,CAAC,QAAQ;oBAC/B,MAAM,EAAE,KAAK,CAAC,SAAS,CAAC,WAAW,CAAC,eAAe,EAAE;iBACrD,CAAC,CAAC;aACH;QACF,CAAC,CAAC,CAAC;QACJ,OAAO,IAAI,CAAC;IACb,CAAC;CACD,CAAC","sourcesContent":["import { CardIds } from '@firestone-hs/reference-data';\r\nimport { BoardEntity } from '../../../board-entity';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\n\r\nexport const TheUninvitedGuest = {\r\n\tstartOfCombat: (minion: BoardEntity, input: SoCInput) => {\r\n\t\tconst targetEnchantment =\r\n\t\t\tminion.cardId === CardIds.TheUninvitedGuest_BG29_875_G\r\n\t\t\t\t? CardIds.TheUninvitedGuest_UninvitedEnchantment_BG29_875_Ge\r\n\t\t\t\t: CardIds.TheUninvitedGuest_UninvitedEnchantment_BG29_875e;\r\n\t\tinput.playerBoard\r\n\t\t\t.filter((e) => e.entityId != minion.entityId)\r\n\t\t\t.forEach((e) => {\r\n\t\t\t\te.enchantments = e.enchantments || [];\r\n\t\t\t\tif (!e.enchantments.some((e) => e.cardId === targetEnchantment)) {\r\n\t\t\t\t\te.enchantments.push({\r\n\t\t\t\t\t\tcardId: targetEnchantment,\r\n\t\t\t\t\t\toriginEntityId: minion.entityId,\r\n\t\t\t\t\t\ttiming: input.gameState.sharedState.currentEntityId++,\r\n\t\t\t\t\t});\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\treturn true;\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ThousandthPaperDrake = void 0;
|
|
4
|
+
const reference_data_1 = require("@firestone-hs/reference-data");
|
|
5
|
+
const stats_1 = require("../../../simulation/stats");
|
|
6
|
+
const utils_1 = require("../../../utils");
|
|
7
|
+
exports.ThousandthPaperDrake = {
|
|
8
|
+
startOfCombat: (minion, input) => {
|
|
9
|
+
const loops = minion.cardId === "BG29_810_G" ? 2 : 1;
|
|
10
|
+
const pickedTargets = [];
|
|
11
|
+
const dragons = input.playerBoard.filter((e) => (0, utils_1.hasCorrectTribe)(e, input.playerEntity, reference_data_1.Race.DRAGON, input.gameState.allCards));
|
|
12
|
+
for (let i = 0; i < loops; i++) {
|
|
13
|
+
const target = dragons.filter((e) => !pickedTargets.includes(e))[0];
|
|
14
|
+
if (!!target) {
|
|
15
|
+
(0, stats_1.modifyStats)(target, 1, 2, input.playerBoard, input.playerEntity, input.gameState);
|
|
16
|
+
target.windfury = true;
|
|
17
|
+
input.gameState.spectator.registerPowerTarget(minion, target, input.playerBoard, input.playerEntity, input.opponentEntity);
|
|
18
|
+
pickedTargets.push(target);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
return true;
|
|
22
|
+
},
|
|
23
|
+
};
|
|
24
|
+
//# sourceMappingURL=thousandth-paper-drake.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"thousandth-paper-drake.js","sourceRoot":"","sources":["../../../../src/cards/impl/minion/thousandth-paper-drake.ts"],"names":[],"mappings":";;;AAAA,iEAA6D;AAG7D,qDAAwD;AACxD,0CAAiD;AAEpC,QAAA,oBAAoB,GAAG;IACnC,aAAa,EAAE,CAAC,MAAmB,EAAE,KAAe,EAAE,EAAE;QACvD,MAAM,KAAK,GAAG,MAAM,CAAC,MAAM,iBAA4C,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAChF,MAAM,aAAa,GAAG,EAAE,CAAC;QACzB,MAAM,OAAO,GAAG,KAAK,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAC9C,IAAA,uBAAe,EAAC,CAAC,EAAE,KAAK,CAAC,YAAY,EAAE,qBAAI,CAAC,MAAM,EAAE,KAAK,CAAC,SAAS,CAAC,QAAQ,CAAC,CAC7E,CAAC;QACF,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,EAAE,CAAC,EAAE,EAAE;YAC/B,MAAM,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;YACpE,IAAI,CAAC,CAAC,MAAM,EAAE;gBACb,IAAA,mBAAW,EAAC,MAAM,EAAE,CAAC,EAAE,CAAC,EAAE,KAAK,CAAC,WAAW,EAAE,KAAK,CAAC,YAAY,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;gBAClF,MAAM,CAAC,QAAQ,GAAG,IAAI,CAAC;gBACvB,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,mBAAmB,CAC5C,MAAM,EACN,MAAM,EACN,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,cAAc,CACpB,CAAC;gBACF,aAAa,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;aAC3B;SACD;QACD,OAAO,IAAI,CAAC;IACb,CAAC;CACD,CAAC","sourcesContent":["import { CardIds, Race } from '@firestone-hs/reference-data';\r\nimport { BoardEntity } from '../../../board-entity';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\nimport { modifyStats } from '../../../simulation/stats';\r\nimport { hasCorrectTribe } from '../../../utils';\r\n\r\nexport const ThousandthPaperDrake = {\r\n\tstartOfCombat: (minion: BoardEntity, input: SoCInput) => {\r\n\t\tconst loops = minion.cardId === CardIds.ThousandthPaperDrake_BG29_810_G ? 2 : 1;\r\n\t\tconst pickedTargets = [];\r\n\t\tconst dragons = input.playerBoard.filter((e) =>\r\n\t\t\thasCorrectTribe(e, input.playerEntity, Race.DRAGON, input.gameState.allCards),\r\n\t\t);\r\n\t\tfor (let i = 0; i < loops; i++) {\r\n\t\t\tconst target = dragons.filter((e) => !pickedTargets.includes(e))[0];\r\n\t\t\tif (!!target) {\r\n\t\t\t\tmodifyStats(target, 1, 2, input.playerBoard, input.playerEntity, input.gameState);\r\n\t\t\t\ttarget.windfury = true;\r\n\t\t\t\tinput.gameState.spectator.registerPowerTarget(\r\n\t\t\t\t\tminion,\r\n\t\t\t\t\ttarget,\r\n\t\t\t\t\tinput.playerBoard,\r\n\t\t\t\t\tinput.playerEntity,\r\n\t\t\t\t\tinput.opponentEntity,\r\n\t\t\t\t);\r\n\t\t\t\tpickedTargets.push(target);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Vaelastrasz = void 0;
|
|
4
|
+
const stats_1 = require("../../../simulation/stats");
|
|
5
|
+
exports.Vaelastrasz = {
|
|
6
|
+
startOfCombat: (minion, input) => {
|
|
7
|
+
const vaelastraszBonus = minion.cardId === "TB_BaconShop_HERO_56_Buddy_G" ? 6 : 3;
|
|
8
|
+
input.playerBoard
|
|
9
|
+
.filter((e) => e.entityId !== minion.entityId)
|
|
10
|
+
.forEach((e) => {
|
|
11
|
+
(0, stats_1.modifyStats)(e, vaelastraszBonus, vaelastraszBonus, input.playerBoard, input.playerEntity, input.gameState);
|
|
12
|
+
input.gameState.spectator.registerPowerTarget(minion, e, input.playerBoard, input.playerEntity, input.opponentEntity);
|
|
13
|
+
});
|
|
14
|
+
return true;
|
|
15
|
+
},
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=vaelastrasz.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vaelastrasz.js","sourceRoot":"","sources":["../../../../src/cards/impl/minion/vaelastrasz.ts"],"names":[],"mappings":";;;AAGA,qDAAwD;AAE3C,QAAA,WAAW,GAAG;IAC1B,aAAa,EAAE,CAAC,MAAmB,EAAE,KAAe,EAAE,EAAE;QACvD,MAAM,gBAAgB,GAAG,MAAM,CAAC,MAAM,mCAAqD,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QACpG,KAAK,CAAC,WAAW;aACf,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,KAAK,MAAM,CAAC,QAAQ,CAAC;aAC7C,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE;YACd,IAAA,mBAAW,EACV,CAAC,EACD,gBAAgB,EAChB,gBAAgB,EAChB,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,SAAS,CACf,CAAC;YACF,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,mBAAmB,CAC5C,MAAM,EACN,CAAC,EACD,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,cAAc,CACpB,CAAC;QACH,CAAC,CAAC,CAAC;QACJ,OAAO,IAAI,CAAC;IACb,CAAC;CACD,CAAC","sourcesContent":["import { CardIds } from '@firestone-hs/reference-data';\r\nimport { BoardEntity } from '../../../board-entity';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\nimport { modifyStats } from '../../../simulation/stats';\r\n\r\nexport const Vaelastrasz = {\r\n\tstartOfCombat: (minion: BoardEntity, input: SoCInput) => {\r\n\t\tconst vaelastraszBonus = minion.cardId === CardIds.Vaelastrasz_TB_BaconShop_HERO_56_Buddy_G ? 6 : 3;\r\n\t\tinput.playerBoard\r\n\t\t\t.filter((e) => e.entityId !== minion.entityId)\r\n\t\t\t.forEach((e) => {\r\n\t\t\t\tmodifyStats(\r\n\t\t\t\t\te,\r\n\t\t\t\t\tvaelastraszBonus,\r\n\t\t\t\t\tvaelastraszBonus,\r\n\t\t\t\t\tinput.playerBoard,\r\n\t\t\t\t\tinput.playerEntity,\r\n\t\t\t\t\tinput.gameState,\r\n\t\t\t\t);\r\n\t\t\t\tinput.gameState.spectator.registerPowerTarget(\r\n\t\t\t\t\tminion,\r\n\t\t\t\t\te,\r\n\t\t\t\t\tinput.playerBoard,\r\n\t\t\t\t\tinput.playerEntity,\r\n\t\t\t\t\tinput.opponentEntity,\r\n\t\t\t\t);\r\n\t\t\t});\r\n\t\treturn true;\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.YulonFortuneGranter = void 0;
|
|
4
|
+
const utils_1 = require("../../../services/utils");
|
|
5
|
+
const golden_1 = require("../../../simulation/utils/golden");
|
|
6
|
+
const utils_2 = require("../../../utils");
|
|
7
|
+
exports.YulonFortuneGranter = {
|
|
8
|
+
startOfCombat: (minion, input) => {
|
|
9
|
+
const loops = minion.cardId === "BG29_811_G" ? 2 : 1;
|
|
10
|
+
for (let i = 0; i < loops; i++) {
|
|
11
|
+
const candidateBoard = input.playerBoard
|
|
12
|
+
.filter((e) => !(0, utils_2.isGolden)(e.cardId, input.gameState.allCards))
|
|
13
|
+
.filter((e) => e.cardId !== "BG29_811" &&
|
|
14
|
+
e.cardId !== "BG29_811_G");
|
|
15
|
+
const randomBoard = (0, utils_1.shuffleArray)(candidateBoard);
|
|
16
|
+
const candidates = randomBoard.sort((a, b) => input.gameState.cardsData.getTavernLevel(a.cardId) -
|
|
17
|
+
input.gameState.cardsData.getTavernLevel(b.cardId));
|
|
18
|
+
const target = candidates[0];
|
|
19
|
+
if (!!target) {
|
|
20
|
+
(0, golden_1.makeMinionGolden)(target, minion, input.playerBoard, input.playerEntity, input.opponentEntity, input.gameState);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
return true;
|
|
24
|
+
},
|
|
25
|
+
};
|
|
26
|
+
//# sourceMappingURL=yulon-fortune-granter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"yulon-fortune-granter.js","sourceRoot":"","sources":["../../../../src/cards/impl/minion/yulon-fortune-granter.ts"],"names":[],"mappings":";;;AAEA,mDAAuD;AAEvD,6DAAoE;AACpE,0CAA0C;AAE7B,QAAA,mBAAmB,GAAG;IAClC,aAAa,EAAE,CAAC,MAAmB,EAAE,KAAe,EAAE,EAAE;QACvD,MAAM,KAAK,GAAG,MAAM,CAAC,MAAM,iBAA2C,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAC/E,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,EAAE,CAAC,EAAE,EAAE;YAC/B,MAAM,cAAc,GAAG,KAAK,CAAC,WAAW;iBACtC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,IAAA,gBAAQ,EAAC,CAAC,CAAC,MAAM,EAAE,KAAK,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;iBAC5D,MAAM,CACN,CAAC,CAAC,EAAE,EAAE,CACL,CAAC,CAAC,MAAM,eAAyC;gBACjD,CAAC,CAAC,MAAM,iBAA2C,CACpD,CAAC;YAEH,MAAM,WAAW,GAAG,IAAA,oBAAY,EAAC,cAAc,CAAC,CAAC;YACjD,MAAM,UAAU,GAAG,WAAW,CAAC,IAAI,CAClC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CACR,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC,CAAC,MAAM,CAAC;gBAClD,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC,CAAC,MAAM,CAAC,CACnD,CAAC;YACF,MAAM,MAAM,GAAG,UAAU,CAAC,CAAC,CAAC,CAAC;YAC7B,IAAI,CAAC,CAAC,MAAM,EAAE;gBACb,IAAA,yBAAgB,EACf,MAAM,EACN,MAAM,EACN,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,cAAc,EACpB,KAAK,CAAC,SAAS,CACf,CAAC;aACF;SACD;QACD,OAAO,IAAI,CAAC;IACb,CAAC;CACD,CAAC","sourcesContent":["import { CardIds } from '@firestone-hs/reference-data';\r\nimport { BoardEntity } from '../../../board-entity';\r\nimport { shuffleArray } from '../../../services/utils';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\nimport { makeMinionGolden } from '../../../simulation/utils/golden';\r\nimport { isGolden } from '../../../utils';\r\n\r\nexport const YulonFortuneGranter = {\r\n\tstartOfCombat: (minion: BoardEntity, input: SoCInput) => {\r\n\t\tconst loops = minion.cardId === CardIds.YulonFortuneGranter_BG29_811_G ? 2 : 1;\r\n\t\tfor (let i = 0; i < loops; i++) {\r\n\t\t\tconst candidateBoard = input.playerBoard\r\n\t\t\t\t.filter((e) => !isGolden(e.cardId, input.gameState.allCards))\r\n\t\t\t\t.filter(\r\n\t\t\t\t\t(e) =>\r\n\t\t\t\t\t\te.cardId !== CardIds.YulonFortuneGranter_BG29_811 &&\r\n\t\t\t\t\t\te.cardId !== CardIds.YulonFortuneGranter_BG29_811_G,\r\n\t\t\t\t);\r\n\t\t\t// Because we pick one at random from all the ones that have the lowest tier\r\n\t\t\tconst randomBoard = shuffleArray(candidateBoard);\r\n\t\t\tconst candidates = randomBoard.sort(\r\n\t\t\t\t(a, b) =>\r\n\t\t\t\t\tinput.gameState.cardsData.getTavernLevel(a.cardId) -\r\n\t\t\t\t\tinput.gameState.cardsData.getTavernLevel(b.cardId),\r\n\t\t\t);\r\n\t\t\tconst target = candidates[0];\r\n\t\t\tif (!!target) {\r\n\t\t\t\tmakeMinionGolden(\r\n\t\t\t\t\ttarget,\r\n\t\t\t\t\tminion,\r\n\t\t\t\t\tinput.playerBoard,\r\n\t\t\t\t\tinput.playerEntity,\r\n\t\t\t\t\tinput.opponentEntity,\r\n\t\t\t\t\tinput.gameState,\r\n\t\t\t\t);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.EvilTwin = void 0;
|
|
4
|
+
const deathrattle_spawns_1 = require("../../../simulation/deathrattle-spawns");
|
|
5
|
+
const spawns_1 = require("../../../simulation/spawns");
|
|
6
|
+
exports.EvilTwin = {
|
|
7
|
+
startOfCombat: (trinket, input) => {
|
|
8
|
+
if (!!input.playerBoard.length && input.playerBoard.length < 7) {
|
|
9
|
+
const highestHealthMinion = [...input.playerBoard].sort((a, b) => b.health - a.health)[0];
|
|
10
|
+
const copy = {
|
|
11
|
+
...highestHealthMinion,
|
|
12
|
+
lastAffectedByEntity: null,
|
|
13
|
+
};
|
|
14
|
+
const newMinions = (0, deathrattle_spawns_1.spawnEntities)(copy.cardId, 1, input.playerBoard, input.playerEntity, input.opponentBoard, input.opponentEntity, input.gameState.allCards, input.gameState.cardsData, input.gameState.sharedState, input.gameState.spectator, highestHealthMinion.friendly, true, false, false, copy);
|
|
15
|
+
const indexFromRight = input.playerBoard.length - (input.playerBoard.indexOf(highestHealthMinion) + 1);
|
|
16
|
+
(0, spawns_1.performEntitySpawns)(newMinions, input.playerBoard, input.playerEntity, highestHealthMinion, indexFromRight, input.opponentBoard, input.opponentEntity, input.gameState);
|
|
17
|
+
input.gameState.spectator.registerPowerTarget(input.playerEntity, copy, input.playerBoard, null, null);
|
|
18
|
+
input.currentAttacker =
|
|
19
|
+
input.playerBoard.length > input.opponentBoard.length
|
|
20
|
+
? input.playerIsFriendly
|
|
21
|
+
? 0
|
|
22
|
+
: 1
|
|
23
|
+
: input.opponentBoard.length > input.playerBoard.length
|
|
24
|
+
? input.playerIsFriendly
|
|
25
|
+
? 1
|
|
26
|
+
: 0
|
|
27
|
+
: Math.round(Math.random());
|
|
28
|
+
return true;
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
};
|
|
32
|
+
//# sourceMappingURL=evil-twin.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"evil-twin.js","sourceRoot":"","sources":["../../../../src/cards/impl/quest-reward/evil-twin.ts"],"names":[],"mappings":";;;AAEA,+EAAuE;AACvE,uDAAiE;AAGpD,QAAA,QAAQ,GAAG;IACvB,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;QACzD,IAAI,CAAC,CAAC,KAAK,CAAC,WAAW,CAAC,MAAM,IAAI,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,EAAE;YAC/D,MAAM,mBAAmB,GAAG,CAAC,GAAG,KAAK,CAAC,WAAW,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,GAAG,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;YAC1F,MAAM,IAAI,GAAgB;gBACzB,GAAG,mBAAmB;gBACtB,oBAAoB,EAAE,IAAI;aAC1B,CAAC;YACF,MAAM,UAAU,GAAG,IAAA,kCAAa,EAC/B,IAAI,CAAC,MAAM,EACX,CAAC,EACD,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,aAAa,EACnB,KAAK,CAAC,cAAc,EACpB,KAAK,CAAC,SAAS,CAAC,QAAQ,EACxB,KAAK,CAAC,SAAS,CAAC,SAAS,EACzB,KAAK,CAAC,SAAS,CAAC,WAAW,EAC3B,KAAK,CAAC,SAAS,CAAC,SAAS,EACzB,mBAAmB,CAAC,QAAQ,EAC5B,IAAI,EACJ,KAAK,EACL,KAAK,EACL,IAAI,CACJ,CAAC;YACF,MAAM,cAAc,GAAG,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,KAAK,CAAC,WAAW,CAAC,OAAO,CAAC,mBAAmB,CAAC,GAAG,CAAC,CAAC,CAAC;YACvG,IAAA,4BAAmB,EAClB,UAAU,EACV,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,mBAAmB,EACnB,cAAc,EACd,KAAK,CAAC,aAAa,EACnB,KAAK,CAAC,cAAc,EACpB,KAAK,CAAC,SAAS,CACf,CAAC;YACF,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,mBAAmB,CAAC,KAAK,CAAC,YAAY,EAAE,IAAI,EAAE,KAAK,CAAC,WAAW,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;YAGvG,KAAK,CAAC,eAAe;gBACpB,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,KAAK,CAAC,aAAa,CAAC,MAAM;oBACpD,CAAC,CAAC,KAAK,CAAC,gBAAgB;wBACvB,CAAC,CAAC,CAAC;wBACH,CAAC,CAAC,CAAC;oBACJ,CAAC,CAAC,KAAK,CAAC,aAAa,CAAC,MAAM,GAAG,KAAK,CAAC,WAAW,CAAC,MAAM;wBACvD,CAAC,CAAC,KAAK,CAAC,gBAAgB;4BACvB,CAAC,CAAC,CAAC;4BACH,CAAC,CAAC,CAAC;wBACJ,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC,CAAC;YAC9B,OAAO,IAAI,CAAC;SACZ;IACF,CAAC;CACD,CAAC","sourcesContent":["import { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { BoardEntity } from '../../../board-entity';\r\nimport { spawnEntities } from '../../../simulation/deathrattle-spawns';\r\nimport { performEntitySpawns } from '../../../simulation/spawns';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\n\r\nexport const EvilTwin = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tif (!!input.playerBoard.length && input.playerBoard.length < 7) {\r\n\t\t\tconst highestHealthMinion = [...input.playerBoard].sort((a, b) => b.health - a.health)[0];\r\n\t\t\tconst copy: BoardEntity = {\r\n\t\t\t\t...highestHealthMinion,\r\n\t\t\t\tlastAffectedByEntity: null,\r\n\t\t\t};\r\n\t\t\tconst newMinions = spawnEntities(\r\n\t\t\t\tcopy.cardId,\r\n\t\t\t\t1,\r\n\t\t\t\tinput.playerBoard,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tinput.opponentBoard,\r\n\t\t\t\tinput.opponentEntity,\r\n\t\t\t\tinput.gameState.allCards,\r\n\t\t\t\tinput.gameState.cardsData,\r\n\t\t\t\tinput.gameState.sharedState,\r\n\t\t\t\tinput.gameState.spectator,\r\n\t\t\t\thighestHealthMinion.friendly,\r\n\t\t\t\ttrue,\r\n\t\t\t\tfalse,\r\n\t\t\t\tfalse,\r\n\t\t\t\tcopy,\r\n\t\t\t);\r\n\t\t\tconst indexFromRight = input.playerBoard.length - (input.playerBoard.indexOf(highestHealthMinion) + 1);\r\n\t\t\tperformEntitySpawns(\r\n\t\t\t\tnewMinions,\r\n\t\t\t\tinput.playerBoard,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\thighestHealthMinion,\r\n\t\t\t\tindexFromRight,\r\n\t\t\t\tinput.opponentBoard,\r\n\t\t\t\tinput.opponentEntity,\r\n\t\t\t\tinput.gameState,\r\n\t\t\t);\r\n\t\t\tinput.gameState.spectator.registerPowerTarget(input.playerEntity, copy, input.playerBoard, null, null);\r\n\t\t\t// Recompute first attacker\r\n\t\t\t// See https://replays.firestoneapp.com/?reviewId=93229c4a-d864-4196-83dd-2fea2a5bf70a&turn=29&action=0\r\n\t\t\tinput.currentAttacker =\r\n\t\t\t\tinput.playerBoard.length > input.opponentBoard.length\r\n\t\t\t\t\t? input.playerIsFriendly\r\n\t\t\t\t\t\t? 0\r\n\t\t\t\t\t\t: 1\r\n\t\t\t\t\t: input.opponentBoard.length > input.playerBoard.length\r\n\t\t\t\t\t? input.playerIsFriendly\r\n\t\t\t\t\t\t? 1\r\n\t\t\t\t\t\t: 0\r\n\t\t\t\t\t: Math.round(Math.random());\r\n\t\t\treturn true;\r\n\t\t}\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.StaffOfOrigination = void 0;
|
|
4
|
+
const stats_1 = require("../../../simulation/stats");
|
|
5
|
+
exports.StaffOfOrigination = {
|
|
6
|
+
startOfCombat: (trinket, input) => {
|
|
7
|
+
input.playerBoard.forEach((entity) => {
|
|
8
|
+
(0, stats_1.modifyStats)(entity, 15, 15, input.playerBoard, input.playerEntity, input.gameState);
|
|
9
|
+
input.gameState.spectator.registerPowerTarget(input.playerEntity, entity, input.playerBoard, null, null);
|
|
10
|
+
});
|
|
11
|
+
return true;
|
|
12
|
+
},
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=staff-of-origination.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"staff-of-origination.js","sourceRoot":"","sources":["../../../../src/cards/impl/quest-reward/staff-of-origination.ts"],"names":[],"mappings":";;;AAEA,qDAAwD;AAE3C,QAAA,kBAAkB,GAAG;IACjC,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;QACzD,KAAK,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,EAAE;YACpC,IAAA,mBAAW,EAAC,MAAM,EAAE,EAAE,EAAE,EAAE,EAAE,KAAK,CAAC,WAAW,EAAE,KAAK,CAAC,YAAY,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;YACpF,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,mBAAmB,CAAC,KAAK,CAAC,YAAY,EAAE,MAAM,EAAE,KAAK,CAAC,WAAW,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;QAC1G,CAAC,CAAC,CAAC;QACH,OAAO,IAAI,CAAC;IACb,CAAC;CACD,CAAC","sourcesContent":["import { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\nimport { modifyStats } from '../../../simulation/stats';\r\n\r\nexport const StaffOfOrigination = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tinput.playerBoard.forEach((entity) => {\r\n\t\t\tmodifyStats(entity, 15, 15, input.playerBoard, input.playerEntity, input.gameState);\r\n\t\t\tinput.gameState.spectator.registerPowerTarget(input.playerEntity, entity, input.playerBoard, null, null);\r\n\t\t});\r\n\t\treturn true;\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.StolenGold = void 0;
|
|
4
|
+
const golden_1 = require("../../../simulation/utils/golden");
|
|
5
|
+
exports.StolenGold = {
|
|
6
|
+
startOfCombat: (trinket, input) => {
|
|
7
|
+
if (input.playerBoard.length > 0) {
|
|
8
|
+
(0, golden_1.makeMinionGolden)(input.playerBoard[0], input.playerEntity, input.playerBoard, input.playerEntity, input.opponentEntity, input.gameState);
|
|
9
|
+
if (input.playerBoard.length > 1) {
|
|
10
|
+
(0, golden_1.makeMinionGolden)(input.playerBoard[input.playerBoard.length - 1], input.playerEntity, input.playerBoard, input.playerEntity, input.opponentEntity, input.gameState);
|
|
11
|
+
}
|
|
12
|
+
return true;
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=stolen-gold.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stolen-gold.js","sourceRoot":"","sources":["../../../../src/cards/impl/quest-reward/stolen-gold.ts"],"names":[],"mappings":";;;AAEA,6DAAoE;AAEvD,QAAA,UAAU,GAAG;IACzB,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;QACzD,IAAI,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,EAAE;YACjC,IAAA,yBAAgB,EACf,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC,EACpB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,cAAc,EACpB,KAAK,CAAC,SAAS,CACf,CAAC;YACF,IAAI,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,EAAE;gBACjC,IAAA,yBAAgB,EACf,KAAK,CAAC,WAAW,CAAC,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,CAAC,EAC/C,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,cAAc,EACpB,KAAK,CAAC,SAAS,CACf,CAAC;aACF;YACD,OAAO,IAAI,CAAC;SACZ;IACF,CAAC;CACD,CAAC","sourcesContent":["import { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\nimport { makeMinionGolden } from '../../../simulation/utils/golden';\r\n\r\nexport const StolenGold = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tif (input.playerBoard.length > 0) {\r\n\t\t\tmakeMinionGolden(\r\n\t\t\t\tinput.playerBoard[0],\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tinput.playerBoard,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tinput.opponentEntity,\r\n\t\t\t\tinput.gameState,\r\n\t\t\t);\r\n\t\t\tif (input.playerBoard.length > 1) {\r\n\t\t\t\tmakeMinionGolden(\r\n\t\t\t\t\tinput.playerBoard[input.playerBoard.length - 1],\r\n\t\t\t\t\tinput.playerEntity,\r\n\t\t\t\t\tinput.playerBoard,\r\n\t\t\t\t\tinput.playerEntity,\r\n\t\t\t\t\tinput.opponentEntity,\r\n\t\t\t\t\tinput.gameState,\r\n\t\t\t\t);\r\n\t\t\t}\r\n\t\t\treturn true;\r\n\t\t}\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ArtisanalUrn = void 0;
|
|
4
|
+
exports.ArtisanalUrn = {
|
|
5
|
+
startOfCombat: (trinket, input) => {
|
|
6
|
+
var _a;
|
|
7
|
+
const artisanalUrnBuff = trinket.cardId === "BG30_MagicItem_989" ? 3 : 8;
|
|
8
|
+
input.playerEntity.globalInfo.UndeadAttackBonus =
|
|
9
|
+
((_a = input.playerEntity.globalInfo.UndeadAttackBonus) !== null && _a !== void 0 ? _a : 0) + artisanalUrnBuff;
|
|
10
|
+
return true;
|
|
11
|
+
},
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=artisanal-urn.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"artisanal-urn.js","sourceRoot":"","sources":["../../../../src/cards/impl/trinket/artisanal-urn.ts"],"names":[],"mappings":";;;AAIa,QAAA,YAAY,GAAG;IAC3B,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;;QACzD,MAAM,gBAAgB,GAAG,OAAO,CAAC,MAAM,yBAA4C,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAC5F,KAAK,CAAC,YAAY,CAAC,UAAU,CAAC,iBAAiB;YAC9C,CAAC,MAAA,KAAK,CAAC,YAAY,CAAC,UAAU,CAAC,iBAAiB,mCAAI,CAAC,CAAC,GAAG,gBAAgB,CAAC;QAC3E,OAAO,IAAI,CAAC;IACb,CAAC;CACD,CAAC","sourcesContent":["import { CardIds } from '@firestone-hs/reference-data';\r\nimport { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\n\r\nexport const ArtisanalUrn = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tconst artisanalUrnBuff = trinket.cardId === CardIds.ArtisanalUrn_BG30_MagicItem_989 ? 3 : 8;\r\n\t\tinput.playerEntity.globalInfo.UndeadAttackBonus =\r\n\t\t\t(input.playerEntity.globalInfo.UndeadAttackBonus ?? 0) + artisanalUrnBuff;\r\n\t\treturn true;\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AutomatonPortrait = void 0;
|
|
4
|
+
const deathrattle_spawns_1 = require("../../../simulation/deathrattle-spawns");
|
|
5
|
+
const spawns_1 = require("../../../simulation/spawns");
|
|
6
|
+
exports.AutomatonPortrait = {
|
|
7
|
+
startOfCombat: (trinket, input) => {
|
|
8
|
+
if (input.playerBoard.length < 7) {
|
|
9
|
+
const newMinions = (0, deathrattle_spawns_1.spawnEntities)("BG_TTN_401", 1, input.playerBoard, input.playerEntity, input.opponentBoard, input.opponentEntity, input.gameState.allCards, input.gameState.cardsData, input.gameState.sharedState, input.gameState.spectator, input.playerEntity.friendly, true);
|
|
10
|
+
(0, spawns_1.performEntitySpawns)(newMinions, input.playerBoard, input.playerEntity, input.playerEntity, 0, input.opponentBoard, input.opponentEntity, input.gameState);
|
|
11
|
+
return true;
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
};
|
|
15
|
+
//# sourceMappingURL=automaton-portrait.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"automaton-portrait.js","sourceRoot":"","sources":["../../../../src/cards/impl/trinket/automaton-portrait.ts"],"names":[],"mappings":";;;AAEA,+EAAuE;AACvE,uDAAiE;AAGpD,QAAA,iBAAiB,GAAG;IAChC,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;QACzD,IAAI,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,EAAE;YACjC,MAAM,UAAU,GAAG,IAAA,kCAAa,gBAE/B,CAAC,EACD,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,aAAa,EACnB,KAAK,CAAC,cAAc,EACpB,KAAK,CAAC,SAAS,CAAC,QAAQ,EACxB,KAAK,CAAC,SAAS,CAAC,SAAS,EACzB,KAAK,CAAC,SAAS,CAAC,WAAW,EAC3B,KAAK,CAAC,SAAS,CAAC,SAAS,EACzB,KAAK,CAAC,YAAY,CAAC,QAAQ,EAC3B,IAAI,CACJ,CAAC;YACF,IAAA,4BAAmB,EAClB,UAAU,EACV,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,YAAY,EAClB,CAAC,EACD,KAAK,CAAC,aAAa,EACnB,KAAK,CAAC,cAAc,EACpB,KAAK,CAAC,SAAS,CACf,CAAC;YACF,OAAO,IAAI,CAAC;SACZ;IACF,CAAC;CACD,CAAC","sourcesContent":["import { CardIds } from '@firestone-hs/reference-data';\r\nimport { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { spawnEntities } from '../../../simulation/deathrattle-spawns';\r\nimport { performEntitySpawns } from '../../../simulation/spawns';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\n\r\nexport const AutomatonPortrait = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tif (input.playerBoard.length < 7) {\r\n\t\t\tconst newMinions = spawnEntities(\r\n\t\t\t\tCardIds.AstralAutomaton_BG_TTN_401,\r\n\t\t\t\t1,\r\n\t\t\t\tinput.playerBoard,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tinput.opponentBoard,\r\n\t\t\t\tinput.opponentEntity,\r\n\t\t\t\tinput.gameState.allCards,\r\n\t\t\t\tinput.gameState.cardsData,\r\n\t\t\t\tinput.gameState.sharedState,\r\n\t\t\t\tinput.gameState.spectator,\r\n\t\t\t\tinput.playerEntity.friendly,\r\n\t\t\t\ttrue,\r\n\t\t\t);\r\n\t\t\tperformEntitySpawns(\r\n\t\t\t\tnewMinions,\r\n\t\t\t\tinput.playerBoard,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\t0,\r\n\t\t\t\tinput.opponentBoard,\r\n\t\t\t\tinput.opponentEntity,\r\n\t\t\t\tinput.gameState,\r\n\t\t\t);\r\n\t\t\treturn true;\r\n\t\t}\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BronzeTimepiece = void 0;
|
|
4
|
+
const stats_1 = require("../../../simulation/stats");
|
|
5
|
+
exports.BronzeTimepiece = {
|
|
6
|
+
startOfCombat: (trinket, input) => {
|
|
7
|
+
if (input.playerBoard.length > 0) {
|
|
8
|
+
input.playerBoard.forEach((entity) => {
|
|
9
|
+
const highest = Math.max(entity.attack, entity.health);
|
|
10
|
+
(0, stats_1.setEntityStats)(entity, highest, highest, input.playerBoard, input.playerEntity, input.gameState);
|
|
11
|
+
input.gameState.spectator.registerPowerTarget(trinket, entity, input.playerBoard, null, null);
|
|
12
|
+
});
|
|
13
|
+
return true;
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=bronze-timepiece.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bronze-timepiece.js","sourceRoot":"","sources":["../../../../src/cards/impl/trinket/bronze-timepiece.ts"],"names":[],"mappings":";;;AAEA,qDAA2D;AAE9C,QAAA,eAAe,GAAG;IAC9B,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;QACzD,IAAI,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,EAAE;YACjC,KAAK,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,EAAE;gBACpC,MAAM,OAAO,GAAG,IAAI,CAAC,GAAG,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC;gBACvD,IAAA,sBAAc,EAAC,MAAM,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,CAAC,WAAW,EAAE,KAAK,CAAC,YAAY,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;gBACjG,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,mBAAmB,CAAC,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,WAAW,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;YAC/F,CAAC,CAAC,CAAC;YACH,OAAO,IAAI,CAAC;SACZ;IACF,CAAC;CACD,CAAC","sourcesContent":["import { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\nimport { setEntityStats } from '../../../simulation/stats';\r\n\r\nexport const BronzeTimepiece = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tif (input.playerBoard.length > 0) {\r\n\t\t\tinput.playerBoard.forEach((entity) => {\r\n\t\t\t\tconst highest = Math.max(entity.attack, entity.health);\r\n\t\t\t\tsetEntityStats(entity, highest, highest, input.playerBoard, input.playerEntity, input.gameState);\r\n\t\t\t\tinput.gameState.spectator.registerPowerTarget(trinket, entity, input.playerBoard, null, null);\r\n\t\t\t});\r\n\t\t\treturn true;\r\n\t\t}\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.EmeraldDreamcatcher = void 0;
|
|
4
|
+
const reference_data_1 = require("@firestone-hs/reference-data");
|
|
5
|
+
const stats_1 = require("../../../simulation/stats");
|
|
6
|
+
const utils_1 = require("../../../utils");
|
|
7
|
+
exports.EmeraldDreamcatcher = {
|
|
8
|
+
startOfCombat: (trinket, input) => {
|
|
9
|
+
const highestAttack = Math.max(...input.playerBoard.map((entity) => entity.attack));
|
|
10
|
+
input.playerBoard
|
|
11
|
+
.filter((e) => (0, utils_1.hasCorrectTribe)(e, input.playerEntity, reference_data_1.Race.DRAGON, input.gameState.allCards))
|
|
12
|
+
.forEach((e) => {
|
|
13
|
+
(0, stats_1.setEntityStats)(e, highestAttack, null, input.playerBoard, input.playerEntity, input.gameState);
|
|
14
|
+
});
|
|
15
|
+
return true;
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=emerald-dreamcatcher.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"emerald-dreamcatcher.js","sourceRoot":"","sources":["../../../../src/cards/impl/trinket/emerald-dreamcatcher.ts"],"names":[],"mappings":";;;AAAA,iEAAoD;AAGpD,qDAA2D;AAC3D,0CAAiD;AAEpC,QAAA,mBAAmB,GAAG;IAClC,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;QACzD,MAAM,aAAa,GAAG,IAAI,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC;QACpF,KAAK,CAAC,WAAW;aACf,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAA,uBAAe,EAAC,CAAC,EAAE,KAAK,CAAC,YAAY,EAAE,qBAAI,CAAC,MAAM,EAAE,KAAK,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;aAC5F,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE;YACd,IAAA,sBAAc,EAAC,CAAC,EAAE,aAAa,EAAE,IAAI,EAAE,KAAK,CAAC,WAAW,EAAE,KAAK,CAAC,YAAY,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;QAChG,CAAC,CAAC,CAAC;QACJ,OAAO,IAAI,CAAC;IACb,CAAC;CACD,CAAC","sourcesContent":["import { Race } from '@firestone-hs/reference-data';\r\nimport { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\nimport { setEntityStats } from '../../../simulation/stats';\r\nimport { hasCorrectTribe } from '../../../utils';\r\n\r\nexport const EmeraldDreamcatcher = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tconst highestAttack = Math.max(...input.playerBoard.map((entity) => entity.attack));\r\n\t\tinput.playerBoard\r\n\t\t\t.filter((e) => hasCorrectTribe(e, input.playerEntity, Race.DRAGON, input.gameState.allCards))\r\n\t\t\t.forEach((e) => {\r\n\t\t\t\tsetEntityStats(e, highestAttack, null, input.playerBoard, input.playerEntity, input.gameState);\r\n\t\t\t});\r\n\t\treturn true;\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.EternalPortrait = void 0;
|
|
4
|
+
exports.EternalPortrait = {
|
|
5
|
+
startOfCombat: (trinket, input) => {
|
|
6
|
+
const candidates = input.playerBoard
|
|
7
|
+
.filter((e) => e.cardId === "BG25_008" || e.cardId === "BG25_008_G")
|
|
8
|
+
.filter((e) => !e.taunt || !e.reborn);
|
|
9
|
+
if (candidates === null || candidates === void 0 ? void 0 : candidates.length) {
|
|
10
|
+
candidates.forEach((knight) => {
|
|
11
|
+
knight.taunt = true;
|
|
12
|
+
knight.reborn = true;
|
|
13
|
+
input.gameState.spectator.registerPowerTarget(input.playerEntity, knight, input.playerBoard, null, null);
|
|
14
|
+
});
|
|
15
|
+
return true;
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
};
|
|
19
|
+
//# sourceMappingURL=eternal-portrait.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"eternal-portrait.js","sourceRoot":"","sources":["../../../../src/cards/impl/trinket/eternal-portrait.ts"],"names":[],"mappings":";;;AAIa,QAAA,eAAe,GAAG;IAC9B,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;QACzD,MAAM,UAAU,GAAG,KAAK,CAAC,WAAW;aAClC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,eAAmC,IAAI,CAAC,CAAC,MAAM,iBAAqC,CAAC;aAC3G,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;QACvC,IAAI,UAAU,aAAV,UAAU,uBAAV,UAAU,CAAE,MAAM,EAAE;YACvB,UAAU,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,EAAE;gBAC7B,MAAM,CAAC,KAAK,GAAG,IAAI,CAAC;gBACpB,MAAM,CAAC,MAAM,GAAG,IAAI,CAAC;gBACrB,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,mBAAmB,CAC5C,KAAK,CAAC,YAAY,EAClB,MAAM,EACN,KAAK,CAAC,WAAW,EACjB,IAAI,EACJ,IAAI,CACJ,CAAC;YACH,CAAC,CAAC,CAAC;YACH,OAAO,IAAI,CAAC;SACZ;IACF,CAAC;CACD,CAAC","sourcesContent":["import { CardIds } from '@firestone-hs/reference-data';\r\nimport { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\n\r\nexport const EternalPortrait = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tconst candidates = input.playerBoard\r\n\t\t\t.filter((e) => e.cardId === CardIds.EternalKnight_BG25_008 || e.cardId === CardIds.EternalKnight_BG25_008_G)\r\n\t\t\t.filter((e) => !e.taunt || !e.reborn);\r\n\t\tif (candidates?.length) {\r\n\t\t\tcandidates.forEach((knight) => {\r\n\t\t\t\tknight.taunt = true;\r\n\t\t\t\tknight.reborn = true;\r\n\t\t\t\tinput.gameState.spectator.registerPowerTarget(\r\n\t\t\t\t\tinput.playerEntity,\r\n\t\t\t\t\tknight,\r\n\t\t\t\t\tinput.playerBoard,\r\n\t\t\t\t\tnull,\r\n\t\t\t\t\tnull,\r\n\t\t\t\t);\r\n\t\t\t});\r\n\t\t\treturn true;\r\n\t\t}\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.FishySticker = void 0;
|
|
4
|
+
const deathrattle_spawns_1 = require("../../../simulation/deathrattle-spawns");
|
|
5
|
+
const spawns_1 = require("../../../simulation/spawns");
|
|
6
|
+
exports.FishySticker = {
|
|
7
|
+
startOfCombat: (trinket, input) => {
|
|
8
|
+
if (input.playerBoard.length < 7) {
|
|
9
|
+
const spawnId = trinket.cardId === "BG30_MagicItem_821"
|
|
10
|
+
? "TB_BaconShop_HP_105t"
|
|
11
|
+
: "TB_BaconUps_307";
|
|
12
|
+
const newMinions = (0, deathrattle_spawns_1.spawnEntities)(spawnId, 1, input.playerBoard, input.playerEntity, input.opponentBoard, input.opponentEntity, input.gameState.allCards, input.gameState.cardsData, input.gameState.sharedState, input.gameState.spectator, input.playerEntity.friendly, false);
|
|
13
|
+
const spawns = (0, spawns_1.performEntitySpawns)(newMinions, input.playerBoard, input.playerEntity, input.playerEntity, 0, input.opponentBoard, input.opponentEntity, input.gameState);
|
|
14
|
+
input.currentAttacker =
|
|
15
|
+
input.playerBoard.length > input.opponentBoard.length
|
|
16
|
+
? input.playerIsFriendly
|
|
17
|
+
? 0
|
|
18
|
+
: 1
|
|
19
|
+
: input.opponentBoard.length > input.playerBoard.length
|
|
20
|
+
? input.playerIsFriendly
|
|
21
|
+
? 1
|
|
22
|
+
: 0
|
|
23
|
+
: Math.round(Math.random());
|
|
24
|
+
return true;
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=fishy-sticker.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fishy-sticker.js","sourceRoot":"","sources":["../../../../src/cards/impl/trinket/fishy-sticker.ts"],"names":[],"mappings":";;;AAEA,+EAAuE;AACvE,uDAAiE;AAGpD,QAAA,YAAY,GAAG;IAC3B,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;QACzD,IAAI,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,EAAE;YACjC,MAAM,OAAO,GACZ,OAAO,CAAC,MAAM,yBAA4C;gBACzD,CAAC;gBACD,CAAC,kBAAoB,CAAC;YACxB,MAAM,UAAU,GAAG,IAAA,kCAAa,EAC/B,OAAO,EACP,CAAC,EACD,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,aAAa,EACnB,KAAK,CAAC,cAAc,EACpB,KAAK,CAAC,SAAS,CAAC,QAAQ,EACxB,KAAK,CAAC,SAAS,CAAC,SAAS,EACzB,KAAK,CAAC,SAAS,CAAC,WAAW,EAC3B,KAAK,CAAC,SAAS,CAAC,SAAS,EACzB,KAAK,CAAC,YAAY,CAAC,QAAQ,EAC3B,KAAK,CACL,CAAC;YACF,MAAM,MAAM,GAAG,IAAA,4BAAmB,EACjC,UAAU,EACV,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,YAAY,EAClB,CAAC,EACD,KAAK,CAAC,aAAa,EACnB,KAAK,CAAC,cAAc,EACpB,KAAK,CAAC,SAAS,CACf,CAAC;YACF,KAAK,CAAC,eAAe;gBACpB,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,KAAK,CAAC,aAAa,CAAC,MAAM;oBACpD,CAAC,CAAC,KAAK,CAAC,gBAAgB;wBACvB,CAAC,CAAC,CAAC;wBACH,CAAC,CAAC,CAAC;oBACJ,CAAC,CAAC,KAAK,CAAC,aAAa,CAAC,MAAM,GAAG,KAAK,CAAC,WAAW,CAAC,MAAM;wBACvD,CAAC,CAAC,KAAK,CAAC,gBAAgB;4BACvB,CAAC,CAAC,CAAC;4BACH,CAAC,CAAC,CAAC;wBACJ,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC,CAAC;YAC9B,OAAO,IAAI,CAAC;SACZ;IACF,CAAC;CACD,CAAC","sourcesContent":["import { CardIds } from '@firestone-hs/reference-data';\r\nimport { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { spawnEntities } from '../../../simulation/deathrattle-spawns';\r\nimport { performEntitySpawns } from '../../../simulation/spawns';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\n\r\nexport const FishySticker = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tif (input.playerBoard.length < 7) {\r\n\t\t\tconst spawnId =\r\n\t\t\t\ttrinket.cardId === CardIds.FishySticker_BG30_MagicItem_821\r\n\t\t\t\t\t? CardIds.AvatarOfNzoth_FishOfNzothToken\r\n\t\t\t\t\t: CardIds.FishOfNzoth;\r\n\t\t\tconst newMinions = spawnEntities(\r\n\t\t\t\tspawnId,\r\n\t\t\t\t1,\r\n\t\t\t\tinput.playerBoard,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tinput.opponentBoard,\r\n\t\t\t\tinput.opponentEntity,\r\n\t\t\t\tinput.gameState.allCards,\r\n\t\t\t\tinput.gameState.cardsData,\r\n\t\t\t\tinput.gameState.sharedState,\r\n\t\t\t\tinput.gameState.spectator,\r\n\t\t\t\tinput.playerEntity.friendly,\r\n\t\t\t\tfalse,\r\n\t\t\t);\r\n\t\t\tconst spawns = performEntitySpawns(\r\n\t\t\t\tnewMinions,\r\n\t\t\t\tinput.playerBoard,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\t0,\r\n\t\t\t\tinput.opponentBoard,\r\n\t\t\t\tinput.opponentEntity,\r\n\t\t\t\tinput.gameState,\r\n\t\t\t);\r\n\t\t\tinput.currentAttacker =\r\n\t\t\t\tinput.playerBoard.length > input.opponentBoard.length\r\n\t\t\t\t\t? input.playerIsFriendly\r\n\t\t\t\t\t\t? 0\r\n\t\t\t\t\t\t: 1\r\n\t\t\t\t\t: input.opponentBoard.length > input.playerBoard.length\r\n\t\t\t\t\t? input.playerIsFriendly\r\n\t\t\t\t\t\t? 1\r\n\t\t\t\t\t\t: 0\r\n\t\t\t\t\t: Math.round(Math.random());\r\n\t\t\treturn true;\r\n\t\t}\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.HoggyBank = void 0;
|
|
4
|
+
const reference_data_1 = require("@firestone-hs/reference-data");
|
|
5
|
+
const utils_1 = require("../../../utils");
|
|
6
|
+
exports.HoggyBank = {
|
|
7
|
+
startOfCombat: (trinket, input) => {
|
|
8
|
+
input.playerBoard
|
|
9
|
+
.filter((e) => (0, utils_1.hasCorrectTribe)(e, input.playerEntity, reference_data_1.Race.QUILBOAR, input.gameState.allCards))
|
|
10
|
+
.forEach((e) => {
|
|
11
|
+
var _a;
|
|
12
|
+
e.enchantments = (_a = e.enchantments) !== null && _a !== void 0 ? _a : [];
|
|
13
|
+
e.enchantments.push({
|
|
14
|
+
cardId: "BG30_MagicItem_411e",
|
|
15
|
+
originEntityId: trinket.entityId,
|
|
16
|
+
repeats: 1,
|
|
17
|
+
timing: input.gameState.sharedState.currentEntityId++,
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
return true;
|
|
21
|
+
},
|
|
22
|
+
};
|
|
23
|
+
//# sourceMappingURL=hoggy-bank.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hoggy-bank.js","sourceRoot":"","sources":["../../../../src/cards/impl/trinket/hoggy-bank.ts"],"names":[],"mappings":";;;AAAA,iEAA6D;AAG7D,0CAAiD;AAEpC,QAAA,SAAS,GAAG;IACxB,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;QACzD,KAAK,CAAC,WAAW;aACf,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAA,uBAAe,EAAC,CAAC,EAAE,KAAK,CAAC,YAAY,EAAE,qBAAI,CAAC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;aAC9F,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE;;YACd,CAAC,CAAC,YAAY,GAAG,MAAA,CAAC,CAAC,YAAY,mCAAI,EAAE,CAAC;YACtC,CAAC,CAAC,YAAY,CAAC,IAAI,CAAC;gBACnB,MAAM,uBAA+D;gBACrE,cAAc,EAAE,OAAO,CAAC,QAAQ;gBAChC,OAAO,EAAE,CAAC;gBACV,MAAM,EAAE,KAAK,CAAC,SAAS,CAAC,WAAW,CAAC,eAAe,EAAE;aACrD,CAAC,CAAC;QACJ,CAAC,CAAC,CAAC;QACJ,OAAO,IAAI,CAAC;IACb,CAAC;CACD,CAAC","sourcesContent":["import { CardIds, Race } from '@firestone-hs/reference-data';\r\nimport { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\nimport { hasCorrectTribe } from '../../../utils';\r\n\r\nexport const HoggyBank = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tinput.playerBoard\r\n\t\t\t.filter((e) => hasCorrectTribe(e, input.playerEntity, Race.QUILBOAR, input.gameState.allCards))\r\n\t\t\t.forEach((e) => {\r\n\t\t\t\te.enchantments = e.enchantments ?? [];\r\n\t\t\t\te.enchantments.push({\r\n\t\t\t\t\tcardId: CardIds.HoggyBank_GemInTheBankEnchantment_BG30_MagicItem_411e,\r\n\t\t\t\t\toriginEntityId: trinket.entityId,\r\n\t\t\t\t\trepeats: 1,\r\n\t\t\t\t\ttiming: input.gameState.sharedState.currentEntityId++,\r\n\t\t\t\t});\r\n\t\t\t});\r\n\t\treturn true;\r\n\t},\r\n};\r\n"]}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.HollyMallet = void 0;
|
|
4
|
+
const divine_shield_1 = require("../../../divine-shield");
|
|
5
|
+
exports.HollyMallet = {
|
|
6
|
+
startOfCombat: (trinket, input) => {
|
|
7
|
+
if (input.playerBoard.length > 0) {
|
|
8
|
+
(0, divine_shield_1.updateDivineShield)(input.playerBoard[0], input.playerBoard, input.playerEntity, input.opponentEntity, true, input.gameState);
|
|
9
|
+
input.gameState.spectator.registerPowerTarget(input.playerEntity, input.playerBoard[0], input.playerBoard, null, null);
|
|
10
|
+
if (input.playerBoard.length > 1) {
|
|
11
|
+
(0, divine_shield_1.updateDivineShield)(input.playerBoard[input.playerBoard.length - 1], input.playerBoard, input.playerEntity, input.opponentEntity, true, input.gameState);
|
|
12
|
+
input.gameState.spectator.registerPowerTarget(input.playerEntity, input.playerBoard[input.playerBoard.length - 1], input.playerBoard, null, null);
|
|
13
|
+
}
|
|
14
|
+
return true;
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=holly-mallet.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"holly-mallet.js","sourceRoot":"","sources":["../../../../src/cards/impl/trinket/holly-mallet.ts"],"names":[],"mappings":";;;AACA,0DAA4D;AAG/C,QAAA,WAAW,GAAG;IAC1B,aAAa,EAAE,CAAC,OAAqB,EAAE,KAAe,EAAE,EAAE;QACzD,IAAI,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,EAAE;YACjC,IAAA,kCAAkB,EACjB,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC,EACpB,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,cAAc,EACpB,IAAI,EACJ,KAAK,CAAC,SAAS,CACf,CAAC;YACF,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,mBAAmB,CAC5C,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC,EACpB,KAAK,CAAC,WAAW,EACjB,IAAI,EACJ,IAAI,CACJ,CAAC;YACF,IAAI,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,EAAE;gBACjC,IAAA,kCAAkB,EACjB,KAAK,CAAC,WAAW,CAAC,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,CAAC,EAC/C,KAAK,CAAC,WAAW,EACjB,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,cAAc,EACpB,IAAI,EACJ,KAAK,CAAC,SAAS,CACf,CAAC;gBACF,KAAK,CAAC,SAAS,CAAC,SAAS,CAAC,mBAAmB,CAC5C,KAAK,CAAC,YAAY,EAClB,KAAK,CAAC,WAAW,CAAC,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,CAAC,EAC/C,KAAK,CAAC,WAAW,EACjB,IAAI,EACJ,IAAI,CACJ,CAAC;aACF;YACD,OAAO,IAAI,CAAC;SACZ;IACF,CAAC;CACD,CAAC","sourcesContent":["import { BoardTrinket } from '../../../bgs-player-entity';\r\nimport { updateDivineShield } from '../../../divine-shield';\r\nimport { SoCInput } from '../../../simulation/start-of-combat/start-of-combat-input';\r\n\r\nexport const HollyMallet = {\r\n\tstartOfCombat: (trinket: BoardTrinket, input: SoCInput) => {\r\n\t\tif (input.playerBoard.length > 0) {\r\n\t\t\tupdateDivineShield(\r\n\t\t\t\tinput.playerBoard[0],\r\n\t\t\t\tinput.playerBoard,\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tinput.opponentEntity,\r\n\t\t\t\ttrue,\r\n\t\t\t\tinput.gameState,\r\n\t\t\t);\r\n\t\t\tinput.gameState.spectator.registerPowerTarget(\r\n\t\t\t\tinput.playerEntity,\r\n\t\t\t\tinput.playerBoard[0],\r\n\t\t\t\tinput.playerBoard,\r\n\t\t\t\tnull,\r\n\t\t\t\tnull,\r\n\t\t\t);\r\n\t\t\tif (input.playerBoard.length > 1) {\r\n\t\t\t\tupdateDivineShield(\r\n\t\t\t\t\tinput.playerBoard[input.playerBoard.length - 1],\r\n\t\t\t\t\tinput.playerBoard,\r\n\t\t\t\t\tinput.playerEntity,\r\n\t\t\t\t\tinput.opponentEntity,\r\n\t\t\t\t\ttrue,\r\n\t\t\t\t\tinput.gameState,\r\n\t\t\t\t);\r\n\t\t\t\tinput.gameState.spectator.registerPowerTarget(\r\n\t\t\t\t\tinput.playerEntity,\r\n\t\t\t\t\tinput.playerBoard[input.playerBoard.length - 1],\r\n\t\t\t\t\tinput.playerBoard,\r\n\t\t\t\t\tnull,\r\n\t\t\t\t\tnull,\r\n\t\t\t\t);\r\n\t\t\t}\r\n\t\t\treturn true;\r\n\t\t}\r\n\t},\r\n};\r\n"]}
|