@firestone-hs/simulate-bgs-battle 1.1.501 → 1.1.503
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 +6 -0
- package/dist/bgs-player-entity.js.map +1 -1
- package/dist/cards/card.interface.d.ts +114 -1
- package/dist/cards/card.interface.js +47 -0
- package/dist/cards/card.interface.js.map +1 -1
- package/dist/cards/cards-data.d.ts +5 -1
- package/dist/cards/cards-data.js +39 -6
- package/dist/cards/cards-data.js.map +1 -1
- package/dist/cards/impl/_card-mappings.d.ts +4 -0
- package/dist/cards/impl/_card-mappings.js +154 -0
- package/dist/cards/impl/_card-mappings.js.map +1 -0
- package/dist/cards/impl/anomaly/blessed-or-blighted.js +3 -2
- package/dist/cards/impl/anomaly/blessed-or-blighted.js.map +1 -1
- package/dist/cards/impl/bg-spell/boon-of-beetles.js +1 -1
- package/dist/cards/impl/bg-spell/boon-of-beetles.js.map +1 -1
- package/dist/cards/impl/enchantments/crystal-infuser-enchantment.d.ts +2 -0
- package/dist/cards/impl/enchantments/crystal-infuser-enchantment.js +16 -0
- package/dist/cards/impl/enchantments/crystal-infuser-enchantment.js.map +1 -0
- package/dist/cards/impl/hero-power/reborn-rites.js +2 -1
- package/dist/cards/impl/hero-power/reborn-rites.js.map +1 -1
- package/dist/cards/impl/hero-power/swatting-insects.js +5 -3
- package/dist/cards/impl/hero-power/swatting-insects.js.map +1 -1
- package/dist/cards/impl/hero-power/water-invocation.js +1 -1
- package/dist/cards/impl/hero-power/water-invocation.js.map +1 -1
- package/dist/cards/impl/minion/amber-guardian.js +1 -1
- package/dist/cards/impl/minion/amber-guardian.js.map +1 -1
- package/dist/cards/impl/minion/arcane-cannoneer.d.ts +2 -0
- package/dist/cards/impl/minion/arcane-cannoneer.js +15 -0
- package/dist/cards/impl/minion/arcane-cannoneer.js.map +1 -0
- package/dist/cards/impl/minion/bannerboar.d.ts +2 -0
- package/dist/cards/impl/minion/bannerboar.js +16 -0
- package/dist/cards/impl/minion/bannerboar.js.map +1 -0
- package/dist/cards/impl/minion/beetle.d.ts +2 -0
- package/dist/cards/impl/minion/beetle.js +16 -0
- package/dist/cards/impl/minion/beetle.js.map +1 -0
- package/dist/cards/impl/minion/bird-buddy.d.ts +2 -0
- package/dist/cards/impl/minion/bird-buddy.js +14 -0
- package/dist/cards/impl/minion/bird-buddy.js.map +1 -0
- package/dist/cards/impl/minion/blazing-skyfin.d.ts +2 -0
- package/dist/cards/impl/minion/blazing-skyfin.js +12 -0
- package/dist/cards/impl/minion/blazing-skyfin.js.map +1 -0
- package/dist/cards/impl/minion/boar-gamer.d.ts +2 -0
- package/dist/cards/impl/minion/boar-gamer.js +12 -0
- package/dist/cards/impl/minion/boar-gamer.js.map +1 -0
- package/dist/cards/impl/minion/bubble-gunner.d.ts +2 -0
- package/dist/cards/impl/minion/bubble-gunner.js +44 -0
- package/dist/cards/impl/minion/bubble-gunner.js.map +1 -0
- package/dist/cards/impl/minion/buzzing-vermin.d.ts +2 -0
- package/dist/cards/impl/minion/buzzing-vermin.js +12 -0
- package/dist/cards/impl/minion/buzzing-vermin.js.map +1 -0
- package/dist/cards/impl/minion/cadaver-caretaker.d.ts +2 -0
- package/dist/cards/impl/minion/cadaver-caretaker.js +12 -0
- package/dist/cards/impl/minion/cadaver-caretaker.js.map +1 -0
- package/dist/cards/impl/minion/clunker-junker.d.ts +2 -0
- package/dist/cards/impl/minion/clunker-junker.js +24 -0
- package/dist/cards/impl/minion/clunker-junker.js.map +1 -0
- package/dist/cards/impl/minion/deathly-striker.d.ts +2 -0
- package/dist/cards/impl/minion/deathly-striker.js +32 -0
- package/dist/cards/impl/minion/deathly-striker.js.map +1 -0
- package/dist/cards/impl/minion/deflecto-bot.d.ts +2 -0
- package/dist/cards/impl/minion/deflecto-bot.js +21 -0
- package/dist/cards/impl/minion/deflecto-bot.js.map +1 -0
- package/dist/cards/impl/minion/efficient-engineer.d.ts +2 -0
- package/dist/cards/impl/minion/efficient-engineer.js +24 -0
- package/dist/cards/impl/minion/efficient-engineer.js.map +1 -0
- package/dist/cards/impl/minion/electric-synthesizer.d.ts +2 -0
- package/dist/cards/impl/minion/electric-synthesizer.js +24 -0
- package/dist/cards/impl/minion/electric-synthesizer.js.map +1 -0
- package/dist/cards/impl/minion/fairy-gillmother.d.ts +2 -0
- package/dist/cards/impl/minion/fairy-gillmother.js +18 -0
- package/dist/cards/impl/minion/fairy-gillmother.js.map +1 -0
- package/dist/cards/impl/minion/forest-rover.d.ts +2 -0
- package/dist/cards/impl/minion/forest-rover.js +23 -0
- package/dist/cards/impl/minion/forest-rover.js.map +1 -0
- package/dist/cards/impl/minion/fountain-chiller.d.ts +2 -0
- package/dist/cards/impl/minion/fountain-chiller.js +27 -0
- package/dist/cards/impl/minion/fountain-chiller.js.map +1 -0
- package/dist/cards/impl/minion/gem-rat.d.ts +2 -0
- package/dist/cards/impl/minion/gem-rat.js +12 -0
- package/dist/cards/impl/minion/gem-rat.js.map +1 -0
- package/dist/cards/impl/minion/general-drakkisath.d.ts +2 -0
- package/dist/cards/impl/minion/general-drakkisath.js +17 -0
- package/dist/cards/impl/minion/general-drakkisath.js.map +1 -0
- package/dist/cards/impl/minion/gentle-djinni.d.ts +2 -0
- package/dist/cards/impl/minion/gentle-djinni.js +25 -0
- package/dist/cards/impl/minion/gentle-djinni.js.map +1 -0
- package/dist/cards/impl/minion/goldrinn-the-great-wolf.d.ts +2 -0
- package/dist/cards/impl/minion/goldrinn-the-great-wolf.js +15 -0
- package/dist/cards/impl/minion/goldrinn-the-great-wolf.js.map +1 -0
- package/dist/cards/impl/minion/grease-bot.d.ts +2 -0
- package/dist/cards/impl/minion/grease-bot.js +13 -0
- package/dist/cards/impl/minion/grease-bot.js.map +1 -0
- package/dist/cards/impl/minion/gritty-headhunter.d.ts +2 -0
- package/dist/cards/impl/minion/gritty-headhunter.js +14 -0
- package/dist/cards/impl/minion/gritty-headhunter.js.map +1 -0
- package/dist/cards/impl/minion/hackerfin.d.ts +2 -0
- package/dist/cards/impl/minion/hackerfin.js +21 -0
- package/dist/cards/impl/minion/hackerfin.js.map +1 -0
- package/dist/cards/impl/minion/handless-forsaken.d.ts +2 -0
- package/dist/cards/impl/minion/handless-forsaken.js +12 -0
- package/dist/cards/impl/minion/handless-forsaken.js.map +1 -0
- package/dist/cards/impl/minion/harmless-bonehead.d.ts +2 -0
- package/dist/cards/impl/minion/harmless-bonehead.js +12 -0
- package/dist/cards/impl/minion/harmless-bonehead.js.map +1 -0
- package/dist/cards/impl/minion/holo-rover.d.ts +2 -0
- package/dist/cards/impl/minion/holo-rover.js +16 -0
- package/dist/cards/impl/minion/holo-rover.js.map +1 -0
- package/dist/cards/impl/minion/humming-bird.d.ts +2 -5
- package/dist/cards/impl/minion/humming-bird.js +1 -0
- package/dist/cards/impl/minion/humming-bird.js.map +1 -1
- package/dist/cards/impl/minion/hungry-snapjaw.d.ts +2 -0
- package/dist/cards/impl/minion/hungry-snapjaw.js +17 -0
- package/dist/cards/impl/minion/hungry-snapjaw.js.map +1 -0
- package/dist/cards/impl/minion/hunter-of-gatherers.d.ts +2 -0
- package/dist/cards/impl/minion/hunter-of-gatherers.js +13 -0
- package/dist/cards/impl/minion/hunter-of-gatherers.js.map +1 -0
- package/dist/cards/impl/minion/implant-subject.d.ts +2 -0
- package/dist/cards/impl/minion/implant-subject.js +42 -0
- package/dist/cards/impl/minion/implant-subject.js.map +1 -0
- package/dist/cards/impl/minion/impulsive-trickster.d.ts +2 -0
- package/dist/cards/impl/minion/impulsive-trickster.js +14 -0
- package/dist/cards/impl/minion/impulsive-trickster.js.map +1 -0
- package/dist/cards/impl/minion/indomitable-mount.d.ts +2 -0
- package/dist/cards/impl/minion/indomitable-mount.js +23 -0
- package/dist/cards/impl/minion/indomitable-mount.js.map +1 -0
- package/dist/cards/impl/minion/interrogator-whitemane.js +5 -4
- package/dist/cards/impl/minion/interrogator-whitemane.js.map +1 -1
- package/dist/cards/impl/minion/kalecgos-arcane-aspect.d.ts +2 -0
- package/dist/cards/impl/minion/kalecgos-arcane-aspect.js +13 -0
- package/dist/cards/impl/minion/kalecgos-arcane-aspect.js.map +1 -0
- package/dist/cards/impl/minion/kangors-apprentice.d.ts +2 -0
- package/dist/cards/impl/minion/kangors-apprentice.js +21 -0
- package/dist/cards/impl/minion/kangors-apprentice.js.map +1 -0
- package/dist/cards/impl/minion/karmic-chameleon.d.ts +2 -0
- package/dist/cards/impl/minion/karmic-chameleon.js +27 -0
- package/dist/cards/impl/minion/karmic-chameleon.js.map +1 -0
- package/dist/cards/impl/minion/manasaber.d.ts +2 -0
- package/dist/cards/impl/minion/manasaber.js +14 -0
- package/dist/cards/impl/minion/manasaber.js.map +1 -0
- package/dist/cards/impl/minion/mantid-queen.js +6 -3
- package/dist/cards/impl/minion/mantid-queen.js.map +1 -1
- package/dist/cards/impl/minion/marquee-ticker.d.ts +2 -0
- package/dist/cards/impl/minion/marquee-ticker.js +12 -0
- package/dist/cards/impl/minion/marquee-ticker.js.map +1 -0
- package/dist/cards/impl/minion/mecha-jaraxxus.d.ts +2 -0
- package/dist/cards/impl/minion/mecha-jaraxxus.js +12 -0
- package/dist/cards/impl/minion/mecha-jaraxxus.js.map +1 -0
- package/dist/cards/impl/minion/mechanized-gift-horse.d.ts +2 -0
- package/dist/cards/impl/minion/mechanized-gift-horse.js +13 -0
- package/dist/cards/impl/minion/mechanized-gift-horse.js.map +1 -0
- package/dist/cards/impl/minion/mechorse.d.ts +2 -0
- package/dist/cards/impl/minion/mechorse.js +16 -0
- package/dist/cards/impl/minion/mechorse.js.map +1 -0
- package/dist/cards/impl/minion/misfit-dragonling.d.ts +2 -5
- package/dist/cards/impl/minion/misfit-dragonling.js.map +1 -1
- package/dist/cards/impl/minion/moonsteel-juggernaut.d.ts +2 -0
- package/dist/cards/impl/minion/moonsteel-juggernaut.js +15 -0
- package/dist/cards/impl/minion/moonsteel-juggernaut.js.map +1 -0
- package/dist/cards/impl/minion/murky.d.ts +2 -0
- package/dist/cards/impl/minion/murky.js +20 -0
- package/dist/cards/impl/minion/murky.js.map +1 -0
- package/dist/cards/impl/minion/mutated-lasher.d.ts +2 -0
- package/dist/cards/impl/minion/mutated-lasher.js +26 -0
- package/dist/cards/impl/minion/mutated-lasher.js.map +1 -0
- package/dist/cards/impl/minion/neon-agent.d.ts +2 -0
- package/dist/cards/impl/minion/neon-agent.js +18 -0
- package/dist/cards/impl/minion/neon-agent.js.map +1 -0
- package/dist/cards/impl/minion/nest-swarmer.d.ts +2 -0
- package/dist/cards/impl/minion/nest-swarmer.js +12 -0
- package/dist/cards/impl/minion/nest-swarmer.js.map +1 -0
- package/dist/cards/impl/minion/nether-drake.d.ts +2 -0
- package/dist/cards/impl/minion/nether-drake.js +15 -0
- package/dist/cards/impl/minion/nether-drake.js.map +1 -0
- package/dist/cards/impl/minion/niuzao.d.ts +2 -0
- package/dist/cards/impl/minion/niuzao.js +21 -0
- package/dist/cards/impl/minion/niuzao.js.map +1 -0
- package/dist/cards/impl/minion/operatic-belcher.d.ts +2 -0
- package/dist/cards/impl/minion/operatic-belcher.js +26 -0
- package/dist/cards/impl/minion/operatic-belcher.js.map +1 -0
- package/dist/cards/impl/minion/outback-smolderer.d.ts +2 -0
- package/dist/cards/impl/minion/outback-smolderer.js +17 -0
- package/dist/cards/impl/minion/outback-smolderer.js.map +1 -0
- package/dist/cards/impl/minion/parched-wanderer.d.ts +2 -0
- package/dist/cards/impl/minion/parched-wanderer.js +20 -0
- package/dist/cards/impl/minion/parched-wanderer.js.map +1 -0
- package/dist/cards/impl/minion/prized-promo-drake.d.ts +2 -5
- package/dist/cards/impl/minion/prized-promo-drake.js.map +1 -1
- package/dist/cards/impl/minion/razorgore-the-untamed.d.ts +2 -0
- package/dist/cards/impl/minion/razorgore-the-untamed.js +20 -0
- package/dist/cards/impl/minion/razorgore-the-untamed.js.map +1 -0
- package/dist/cards/impl/minion/reckless-cliffdiver.d.ts +2 -0
- package/dist/cards/impl/minion/reckless-cliffdiver.js +19 -0
- package/dist/cards/impl/minion/reckless-cliffdiver.js.map +1 -0
- package/dist/cards/impl/minion/runed-progenitor.d.ts +2 -0
- package/dist/cards/impl/minion/runed-progenitor.js +24 -0
- package/dist/cards/impl/minion/runed-progenitor.js.map +1 -0
- package/dist/cards/impl/minion/rylak-metalhead.d.ts +2 -0
- package/dist/cards/impl/minion/rylak-metalhead.js +22 -0
- package/dist/cards/impl/minion/rylak-metalhead.js.map +1 -0
- package/dist/cards/impl/minion/salty-hog.d.ts +2 -0
- package/dist/cards/impl/minion/salty-hog.js +17 -0
- package/dist/cards/impl/minion/salty-hog.js.map +1 -0
- package/dist/cards/impl/minion/showy-cyclist.d.ts +2 -0
- package/dist/cards/impl/minion/showy-cyclist.js +14 -0
- package/dist/cards/impl/minion/showy-cyclist.js.map +1 -0
- package/dist/cards/impl/minion/silver-handed-recruit.d.ts +2 -0
- package/dist/cards/impl/minion/silver-handed-recruit.js +17 -0
- package/dist/cards/impl/minion/silver-handed-recruit.js.map +1 -0
- package/dist/cards/impl/minion/sly-raptor.d.ts +2 -0
- package/dist/cards/impl/minion/sly-raptor.js +18 -0
- package/dist/cards/impl/minion/sly-raptor.js.map +1 -0
- package/dist/cards/impl/minion/smolderwing.d.ts +2 -0
- package/dist/cards/impl/minion/smolderwing.js +25 -0
- package/dist/cards/impl/minion/smolderwing.js.map +1 -0
- package/dist/cards/impl/minion/soulsplitter.js +2 -1
- package/dist/cards/impl/minion/soulsplitter.js.map +1 -1
- package/dist/cards/impl/minion/spacefarer.d.ts +2 -0
- package/dist/cards/impl/minion/spacefarer.js +20 -0
- package/dist/cards/impl/minion/spacefarer.js.map +1 -0
- package/dist/cards/impl/minion/sun-screener.js +1 -1
- package/dist/cards/impl/minion/sun-screener.js.map +1 -1
- package/dist/cards/impl/minion/swampstriker.d.ts +2 -0
- package/dist/cards/impl/minion/swampstriker.js +21 -0
- package/dist/cards/impl/minion/swampstriker.js.map +1 -0
- package/dist/cards/impl/minion/thousandth-paper-drake.js +2 -1
- package/dist/cards/impl/minion/thousandth-paper-drake.js.map +1 -1
- package/dist/cards/impl/minion/turquoise-skitterer.d.ts +2 -0
- package/dist/cards/impl/minion/turquoise-skitterer.js +25 -0
- package/dist/cards/impl/minion/turquoise-skitterer.js.map +1 -0
- package/dist/cards/impl/minion/twilight-primordium.d.ts +2 -0
- package/dist/cards/impl/minion/twilight-primordium.js +24 -0
- package/dist/cards/impl/minion/twilight-primordium.js.map +1 -0
- package/dist/cards/impl/minion/ultraviolet-ascendant.d.ts +2 -0
- package/dist/cards/impl/minion/ultraviolet-ascendant.js +14 -0
- package/dist/cards/impl/minion/ultraviolet-ascendant.js.map +1 -0
- package/dist/cards/impl/minion/wandering-wight.d.ts +2 -0
- package/dist/cards/impl/minion/wandering-wight.js +12 -0
- package/dist/cards/impl/minion/wandering-wight.js.map +1 -0
- package/dist/cards/impl/minion/whelp-smuggler.d.ts +2 -0
- package/dist/cards/impl/minion/whelp-smuggler.js +17 -0
- package/dist/cards/impl/minion/whelp-smuggler.js.map +1 -0
- package/dist/cards/impl/minion/wisp-in-the-shell.d.ts +2 -0
- package/dist/cards/impl/minion/wisp-in-the-shell.js +19 -0
- package/dist/cards/impl/minion/wisp-in-the-shell.js.map +1 -0
- package/dist/cards/impl/trinket/eternal-portrait.js +4 -2
- package/dist/cards/impl/trinket/eternal-portrait.js.map +1 -1
- package/dist/cards/impl/trinket/holly-mallet.js +1 -1
- package/dist/cards/impl/trinket/holly-mallet.js.map +1 -1
- package/dist/{divine-shield.d.ts → keywords/divine-shield.d.ts} +11 -3
- package/dist/{divine-shield.js → keywords/divine-shield.js} +19 -14
- package/dist/keywords/divine-shield.js.map +1 -0
- package/dist/keywords/reborn.d.ts +10 -0
- package/dist/keywords/reborn.js +22 -0
- package/dist/keywords/reborn.js.map +1 -0
- package/dist/keywords/stealth.d.ts +10 -0
- package/dist/keywords/stealth.js +22 -0
- package/dist/keywords/stealth.js.map +1 -0
- package/dist/keywords/taunt.d.ts +10 -0
- package/dist/keywords/taunt.js +22 -0
- package/dist/keywords/taunt.js.map +1 -0
- package/dist/keywords/venomous.d.ts +10 -0
- package/dist/keywords/venomous.js +33 -0
- package/dist/keywords/venomous.js.map +1 -0
- package/dist/keywords/windfury.d.ts +10 -0
- package/dist/keywords/windfury.js +22 -0
- package/dist/keywords/windfury.js.map +1 -0
- package/dist/simulate-bgs-battle.d.ts +2 -2
- package/dist/simulate-bgs-battle.js +20 -5
- package/dist/simulate-bgs-battle.js.map +1 -1
- package/dist/simulation/add-minion-to-board.d.ts +23 -0
- package/dist/simulation/add-minion-to-board.js +50 -33
- package/dist/simulation/add-minion-to-board.js.map +1 -1
- package/dist/simulation/after-attack.js +2 -1
- package/dist/simulation/after-attack.js.map +1 -1
- package/dist/simulation/attack.js +7 -24
- package/dist/simulation/attack.js.map +1 -1
- package/dist/simulation/auras.d.ts +1 -1
- package/dist/simulation/auras.js +21 -15
- package/dist/simulation/auras.js.map +1 -1
- package/dist/simulation/avenge.d.ts +7 -0
- package/dist/simulation/avenge.js +223 -229
- package/dist/simulation/avenge.js.map +1 -1
- package/dist/simulation/battlecries.d.ts +8 -0
- package/dist/simulation/battlecries.js +574 -623
- package/dist/simulation/battlecries.js.map +1 -1
- package/dist/simulation/blood-gems.js +1 -1
- package/dist/simulation/blood-gems.js.map +1 -1
- package/dist/simulation/cards-in-hand.d.ts +7 -1
- package/dist/simulation/cards-in-hand.js +14 -0
- package/dist/simulation/cards-in-hand.js.map +1 -1
- package/dist/simulation/damage-effects.js +1 -1
- package/dist/simulation/damage-effects.js.map +1 -1
- package/dist/simulation/deathrattle-effects.d.ts +1 -1
- package/dist/simulation/deathrattle-effects.js +468 -517
- package/dist/simulation/deathrattle-effects.js.map +1 -1
- package/dist/simulation/deathrattle-on-trigger.d.ts +1 -0
- package/dist/simulation/deathrattle-on-trigger.js.map +1 -1
- package/dist/simulation/deathrattle-spawns.d.ts +2 -0
- package/dist/simulation/deathrattle-spawns.js +308 -384
- package/dist/simulation/deathrattle-spawns.js.map +1 -1
- package/dist/simulation/deathrattle-utils.js +1 -1
- package/dist/simulation/deathrattle-utils.js.map +1 -1
- package/dist/simulation/frenzy.js +1 -1
- package/dist/simulation/frenzy.js.map +1 -1
- package/dist/simulation/magnetize.js.map +1 -1
- package/dist/simulation/on-attack.d.ts +13 -1
- package/dist/simulation/on-attack.js +21 -1
- package/dist/simulation/on-attack.js.map +1 -1
- package/dist/simulation/on-being-attacked.js +7 -4
- package/dist/simulation/on-being-attacked.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/soc-action-processor.js +6 -12
- package/dist/simulation/start-of-combat/soc-action-processor.js.map +1 -1
- package/dist/simulation/stats.d.ts +9 -0
- package/dist/simulation/stats.js +23 -14
- package/dist/simulation/stats.js.map +1 -1
- package/dist/temp-card-ids.d.ts +70 -0
- package/dist/temp-card-ids.js.map +1 -1
- package/dist/utils.d.ts +0 -1
- package/dist/utils.js +30 -36
- package/dist/utils.js.map +1 -1
- package/package.json +2 -2
- package/dist/divine-shield.js.map +0 -1
|
@@ -2,12 +2,16 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.rememberDeathrattles = exports.applyMonstrosity = exports.dealDamageToAllMinions = exports.applyWheneverMinionDiesEffect = exports.handleAfterMinionKillsEffect = exports.applyEarthInvocationEnchantment = exports.applyFireInvocationEnchantment = exports.applyWaterInvocationEnchantment = exports.applyLightningInvocationEnchantment = exports.handleDeathrattleEffects = exports.computeDeathrattleMultiplier = void 0;
|
|
4
4
|
const reference_data_1 = require("@firestone-hs/reference-data");
|
|
5
|
-
const
|
|
5
|
+
const card_interface_1 = require("../cards/card.interface");
|
|
6
|
+
const _card_mappings_1 = require("../cards/impl/_card-mappings");
|
|
7
|
+
const divine_shield_1 = require("../keywords/divine-shield");
|
|
8
|
+
const reborn_1 = require("../keywords/reborn");
|
|
9
|
+
const taunt_1 = require("../keywords/taunt");
|
|
10
|
+
const windfury_1 = require("../keywords/windfury");
|
|
6
11
|
const utils_1 = require("../services/utils");
|
|
7
12
|
const simulate_bgs_battle_1 = require("../simulate-bgs-battle");
|
|
8
13
|
const utils_2 = require("../utils");
|
|
9
14
|
const attack_1 = require("./attack");
|
|
10
|
-
const battlecries_1 = require("./battlecries");
|
|
11
15
|
const blood_gems_1 = require("./blood-gems");
|
|
12
16
|
const cards_in_hand_1 = require("./cards-in-hand");
|
|
13
17
|
const deathrattle_on_trigger_1 = require("./deathrattle-on-trigger");
|
|
@@ -46,577 +50,524 @@ const handleDeathrattleEffects = (boardWithDeadEntity, boardWithDeadEntityHero,
|
|
|
46
50
|
deadEntity,
|
|
47
51
|
otherBoard,
|
|
48
52
|
otherBoardHero,
|
|
53
|
+
deadEntityIndexFromRight,
|
|
49
54
|
gameState,
|
|
50
55
|
};
|
|
51
56
|
const cardIds = [deadEntity.cardId, ...((_a = deadEntity.additionalCards) !== null && _a !== void 0 ? _a : [])];
|
|
52
|
-
|
|
57
|
+
const enchantments = [
|
|
53
58
|
...((_b = deadEntity.enchantments) !== null && _b !== void 0 ? _b : []),
|
|
54
59
|
].sort((a, b) => a.timing - b.timing);
|
|
55
|
-
const maxNumberOfGroups = 12;
|
|
56
|
-
const enchantmentGroups = (0, utils_1.groupByFunction)((enchantment) => enchantment.cardId)(enchantments);
|
|
57
|
-
enchantments = Object.keys(enchantmentGroups)
|
|
58
|
-
.filter((cardId) => simulate_bgs_battle_1.VALID_DEATHRATTLE_ENCHANTMENTS.includes(cardId))
|
|
59
|
-
.flatMap((cardId) => {
|
|
60
|
-
let repeatsToApply = enchantmentGroups[cardId].map((e) => e.repeats || 1).reduce((a, b) => a + b, 0);
|
|
61
|
-
if ([
|
|
62
|
-
"BG21_000e",
|
|
63
|
-
"BG21_000_Ge",
|
|
64
|
-
].includes(cardId)) {
|
|
65
|
-
repeatsToApply = repeatsToApply * multiplier;
|
|
66
|
-
}
|
|
67
|
-
const results = [];
|
|
68
|
-
const repeatsPerBuff = Math.max(1, Math.floor(repeatsToApply / maxNumberOfGroups));
|
|
69
|
-
let repeatsDone = 0;
|
|
70
|
-
while (repeatsDone < repeatsToApply) {
|
|
71
|
-
const repeats = Math.min(repeatsPerBuff, repeatsToApply - repeatsDone);
|
|
72
|
-
results.push({
|
|
73
|
-
cardId: cardId,
|
|
74
|
-
repeats: repeats,
|
|
75
|
-
timing: Math.min(...enchantmentGroups[cardId].map((e) => e.timing)),
|
|
76
|
-
});
|
|
77
|
-
repeatsDone += repeatsPerBuff;
|
|
78
|
-
}
|
|
79
|
-
return results;
|
|
80
|
-
});
|
|
81
60
|
for (const deadEntityCardId of cardIds) {
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
61
|
+
const deathrattleImpl = _card_mappings_1.cardMappings[deadEntityCardId];
|
|
62
|
+
if ((0, card_interface_1.hasDeathrattleEffect)(deathrattleImpl)) {
|
|
63
|
+
for (let i = 0; i < multiplier; i++) {
|
|
64
|
+
deathrattleImpl.deathrattleEffect(deadEntity, deathrattleTriggeredInput);
|
|
65
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
else {
|
|
69
|
+
switch (deadEntityCardId) {
|
|
70
|
+
case "BG_OG_221":
|
|
71
|
+
for (let i = 0; i < multiplier; i++) {
|
|
72
|
+
(0, divine_shield_1.grantRandomDivineShield)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, gameState);
|
|
73
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
93
74
|
}
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
101
|
-
}
|
|
102
|
-
break;
|
|
103
|
-
case "TB_BaconUps_014":
|
|
104
|
-
for (let i = 0; i < multiplier; i++) {
|
|
105
|
-
(0, divine_shield_1.grantRandomDivineShield)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, gameState);
|
|
106
|
-
(0, divine_shield_1.grantRandomDivineShield)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, gameState);
|
|
107
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
108
|
-
}
|
|
109
|
-
break;
|
|
110
|
-
case "BG26_888":
|
|
111
|
-
case "BG26_888_G":
|
|
112
|
-
const belcherMultiplier = deadEntityCardId === "BG26_888_G" ? 2 : 1;
|
|
113
|
-
for (let i = 0; i < multiplier; i++) {
|
|
114
|
-
for (let j = 0; j < belcherMultiplier; j++) {
|
|
115
|
-
const possibleBelcherTargets = boardWithDeadEntity
|
|
116
|
-
.filter((entity) => !entity.venomous)
|
|
117
|
-
.filter((entity) => !entity.poisonous)
|
|
118
|
-
.filter((entity) => entity.health > 0 && !entity.definitelyDead)
|
|
119
|
-
.filter((entity) => (0, utils_2.hasCorrectTribe)(entity, boardWithDeadEntityHero, reference_data_1.Race.MURLOC, gameState.allCards));
|
|
120
|
-
if (possibleBelcherTargets.length > 0) {
|
|
121
|
-
const chosen = (0, utils_1.pickRandom)(possibleBelcherTargets);
|
|
122
|
-
(0, utils_2.updateVenomous)(chosen, true, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
123
|
-
gameState.spectator.registerPowerTarget(deadEntity, chosen, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
124
|
-
}
|
|
75
|
+
break;
|
|
76
|
+
case "TB_BaconUps_014":
|
|
77
|
+
for (let i = 0; i < multiplier; i++) {
|
|
78
|
+
(0, divine_shield_1.grantRandomDivineShield)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, gameState);
|
|
79
|
+
(0, divine_shield_1.grantRandomDivineShield)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, gameState);
|
|
80
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
125
81
|
}
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
for (let j = 0; j < iterations; j++) {
|
|
134
|
-
let validTargets = boardWithDeadEntity.filter((entity) => !entity.divineShield);
|
|
135
|
-
if (!(validTargets === null || validTargets === void 0 ? void 0 : validTargets.length)) {
|
|
136
|
-
validTargets = boardWithDeadEntity.filter((entity) => !entity.taunt);
|
|
82
|
+
break;
|
|
83
|
+
case "TB_BaconShop_HERO_76_Buddy":
|
|
84
|
+
case "TB_BaconShop_HERO_76_Buddy_G":
|
|
85
|
+
const iterations = deadEntityCardId === "TB_BaconShop_HERO_76_Buddy_G" ? 2 : 1;
|
|
86
|
+
for (let i = 0; i < multiplier; i++) {
|
|
87
|
+
for (let j = 0; j < iterations; j++) {
|
|
88
|
+
let validTargets = boardWithDeadEntity.filter((entity) => !entity.divineShield);
|
|
137
89
|
if (!(validTargets === null || validTargets === void 0 ? void 0 : validTargets.length)) {
|
|
138
|
-
validTargets = boardWithDeadEntity.filter((entity) => !entity.
|
|
90
|
+
validTargets = boardWithDeadEntity.filter((entity) => !entity.taunt);
|
|
91
|
+
if (!(validTargets === null || validTargets === void 0 ? void 0 : validTargets.length)) {
|
|
92
|
+
validTargets = boardWithDeadEntity.filter((entity) => !entity.windfury);
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
const target = (0, utils_1.pickRandom)(validTargets);
|
|
96
|
+
if (target) {
|
|
97
|
+
if (!target.divineShield) {
|
|
98
|
+
(0, divine_shield_1.updateDivineShield)(target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, true, gameState);
|
|
99
|
+
}
|
|
100
|
+
(0, taunt_1.updateTaunt)(target, true, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, gameState);
|
|
101
|
+
(0, windfury_1.updateWindfury)(target, true, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, gameState);
|
|
102
|
+
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
139
103
|
}
|
|
140
104
|
}
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
105
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
106
|
+
}
|
|
107
|
+
break;
|
|
108
|
+
case "BGS_040":
|
|
109
|
+
case "TB_BaconUps_154":
|
|
110
|
+
for (let i = 0; i < multiplier; i++) {
|
|
111
|
+
const nadinaMultiplier = deadEntityCardId === "TB_BaconUps_154" ? 6 : 3;
|
|
112
|
+
for (let j = 0; j < nadinaMultiplier; j++) {
|
|
113
|
+
const validTargets = boardWithDeadEntity
|
|
114
|
+
.filter((e) => (0, utils_2.hasCorrectTribe)(e, boardWithDeadEntityHero, reference_data_1.Race.DRAGON, gameState.allCards))
|
|
115
|
+
.filter((entity) => !entity.divineShield);
|
|
116
|
+
const target = (0, utils_1.pickRandom)(validTargets);
|
|
117
|
+
if (target) {
|
|
144
118
|
(0, divine_shield_1.updateDivineShield)(target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, true, gameState);
|
|
119
|
+
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
145
120
|
}
|
|
146
|
-
target.taunt = true;
|
|
147
|
-
target.windfury = true;
|
|
148
|
-
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
149
121
|
}
|
|
122
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
150
123
|
}
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
for (let i = 0; i < multiplier; i++) {
|
|
157
|
-
const nadinaMultiplier = deadEntityCardId === "TB_BaconUps_154" ? 6 : 3;
|
|
158
|
-
for (let j = 0; j < nadinaMultiplier; j++) {
|
|
159
|
-
const validTargets = boardWithDeadEntity
|
|
160
|
-
.filter((e) => (0, utils_2.hasCorrectTribe)(e, boardWithDeadEntityHero, reference_data_1.Race.DRAGON, gameState.allCards))
|
|
161
|
-
.filter((entity) => !entity.divineShield);
|
|
162
|
-
const target = (0, utils_1.pickRandom)(validTargets);
|
|
163
|
-
if (target) {
|
|
164
|
-
(0, divine_shield_1.updateDivineShield)(target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, true, gameState);
|
|
165
|
-
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
166
|
-
}
|
|
124
|
+
break;
|
|
125
|
+
case "BG_OG_256":
|
|
126
|
+
for (let i = 0; i < multiplier; i++) {
|
|
127
|
+
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 1, 1, gameState);
|
|
128
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
167
129
|
}
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 1, 1, gameState);
|
|
174
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
175
|
-
}
|
|
176
|
-
break;
|
|
177
|
-
case "TB_BaconUps_025":
|
|
178
|
-
for (let i = 0; i < multiplier; i++) {
|
|
179
|
-
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 2, 2, gameState);
|
|
180
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
181
|
-
}
|
|
182
|
-
break;
|
|
183
|
-
case "BGS_018":
|
|
184
|
-
case "TB_BaconUps_085":
|
|
185
|
-
for (let i = 0; i < multiplier; i++) {
|
|
186
|
-
const goldrinnBuff = deadEntityCardId === "TB_BaconUps_085" ? 6 : 3;
|
|
187
|
-
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, goldrinnBuff, goldrinnBuff, gameState, 'BEAST');
|
|
188
|
-
boardWithDeadEntityHero.globalInfo.GoldrinnBuffAtk += goldrinnBuff;
|
|
189
|
-
boardWithDeadEntityHero.globalInfo.GoldrinnBuffHealth += goldrinnBuff;
|
|
190
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
191
|
-
}
|
|
192
|
-
break;
|
|
193
|
-
case "BG29_871":
|
|
194
|
-
case "BG29_871_G":
|
|
195
|
-
const silithidStats = deadEntity.cardId === "BG29_871_G" ? 2 : 1;
|
|
196
|
-
for (let i = 0; i < multiplier; i++) {
|
|
197
|
-
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, silithidStats, silithidStats, gameState, reference_data_1.Race[reference_data_1.Race.BEAST]);
|
|
198
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
199
|
-
}
|
|
200
|
-
break;
|
|
201
|
-
case "YOD_026":
|
|
202
|
-
for (let i = 0; i < multiplier; i++) {
|
|
203
|
-
(0, utils_2.grantRandomAttack)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, deadEntity.attack, gameState);
|
|
204
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
205
|
-
}
|
|
206
|
-
break;
|
|
207
|
-
case "TB_BaconUps_112":
|
|
208
|
-
for (let i = 0; i < multiplier; i++) {
|
|
209
|
-
(0, utils_2.grantRandomAttack)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, deadEntity.attack, gameState);
|
|
210
|
-
(0, utils_2.grantRandomAttack)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, deadEntity.attack, gameState);
|
|
211
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
212
|
-
}
|
|
213
|
-
break;
|
|
214
|
-
case "BG21_006":
|
|
215
|
-
case "BG21_006_G":
|
|
216
|
-
const tricksterMultiplier = deadEntityCardId === "BG21_006_G" ? 2 : 1;
|
|
217
|
-
for (let i = 0; i < multiplier; i++) {
|
|
218
|
-
for (let j = 0; j < tricksterMultiplier; j++) {
|
|
219
|
-
const targetBoard = boardWithDeadEntity;
|
|
220
|
-
(0, utils_2.grantRandomHealth)(deadEntity, targetBoard, boardWithDeadEntityHero, deadEntity.maxHealth, gameState, true);
|
|
130
|
+
break;
|
|
131
|
+
case "TB_BaconUps_025":
|
|
132
|
+
for (let i = 0; i < multiplier; i++) {
|
|
133
|
+
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 2, 2, gameState);
|
|
134
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
221
135
|
}
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
136
|
+
break;
|
|
137
|
+
case "BG29_871":
|
|
138
|
+
case "BG29_871_G":
|
|
139
|
+
const silithidStats = deadEntity.cardId === "BG29_871_G" ? 2 : 1;
|
|
140
|
+
for (let i = 0; i < multiplier; i++) {
|
|
141
|
+
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, silithidStats, silithidStats, gameState, reference_data_1.Race[reference_data_1.Race.BEAST]);
|
|
142
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
143
|
+
}
|
|
144
|
+
break;
|
|
145
|
+
case "YOD_026":
|
|
146
|
+
for (let i = 0; i < multiplier; i++) {
|
|
147
|
+
(0, utils_2.grantRandomAttack)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, deadEntity.attack, gameState);
|
|
148
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
149
|
+
}
|
|
150
|
+
break;
|
|
151
|
+
case "TB_BaconUps_112":
|
|
152
|
+
for (let i = 0; i < multiplier; i++) {
|
|
153
|
+
(0, utils_2.grantRandomAttack)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, deadEntity.attack, gameState);
|
|
154
|
+
(0, utils_2.grantRandomAttack)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, deadEntity.attack, gameState);
|
|
155
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
156
|
+
}
|
|
157
|
+
break;
|
|
158
|
+
case "BG29_815":
|
|
159
|
+
case "BG29_815_G":
|
|
160
|
+
const nightbaneLoops = deadEntityCardId === "BG29_815_G" ? 2 : 1;
|
|
161
|
+
for (let i = 0; i < multiplier; i++) {
|
|
162
|
+
for (let j = 0; j < nightbaneLoops; j++) {
|
|
163
|
+
const pickedTargetEntityIds = [];
|
|
164
|
+
for (let k = 0; k < 2; k++) {
|
|
165
|
+
const target = (0, utils_1.pickRandomAlive)(boardWithDeadEntity.filter((e) => !pickedTargetEntityIds.includes(e.entityId)));
|
|
166
|
+
if (!!target) {
|
|
167
|
+
pickedTargetEntityIds.push(target.entityId);
|
|
168
|
+
(0, stats_1.modifyStats)(target, deadEntity.attack, 0, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
169
|
+
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, null, null);
|
|
170
|
+
}
|
|
237
171
|
}
|
|
238
172
|
}
|
|
173
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
239
174
|
}
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
applyLeapFroggerEffect(boardWithDeadEntity, boardWithDeadEntityHero, deadEntity, false, gameState, deadEntity.deathrattleRepeats);
|
|
246
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
247
|
-
}
|
|
248
|
-
break;
|
|
249
|
-
case "BG21_000_G":
|
|
250
|
-
for (let i = 0; i < multiplier; i++) {
|
|
251
|
-
applyLeapFroggerEffect(boardWithDeadEntity, boardWithDeadEntityHero, deadEntity, true, gameState, deadEntity.deathrattleRepeats);
|
|
252
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
253
|
-
}
|
|
254
|
-
break;
|
|
255
|
-
case "BG21_001":
|
|
256
|
-
for (let i = 0; i < multiplier; i++) {
|
|
257
|
-
const target = (0, utils_2.grantRandomStats)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 6, 6, reference_data_1.Race.BEAST, true, gameState);
|
|
258
|
-
if (!!target) {
|
|
259
|
-
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
175
|
+
break;
|
|
176
|
+
case "BG21_000":
|
|
177
|
+
for (let i = 0; i < multiplier; i++) {
|
|
178
|
+
applyLeapFroggerEffect(boardWithDeadEntity, boardWithDeadEntityHero, deadEntity, false, gameState, deadEntity.deathrattleRepeats);
|
|
179
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
260
180
|
}
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
const target = (0, utils_2.grantRandomStats)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 12, 12, reference_data_1.Race.BEAST, true, gameState);
|
|
267
|
-
if (!!target) {
|
|
268
|
-
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
181
|
+
break;
|
|
182
|
+
case "BG21_000_G":
|
|
183
|
+
for (let i = 0; i < multiplier; i++) {
|
|
184
|
+
applyLeapFroggerEffect(boardWithDeadEntity, boardWithDeadEntityHero, deadEntity, true, gameState, deadEntity.deathrattleRepeats);
|
|
185
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
269
186
|
}
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
if (!!target) {
|
|
279
|
-
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
187
|
+
break;
|
|
188
|
+
case "BG21_001":
|
|
189
|
+
for (let i = 0; i < multiplier; i++) {
|
|
190
|
+
const target = (0, utils_2.grantRandomStats)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 6, 6, reference_data_1.Race.BEAST, true, gameState);
|
|
191
|
+
if (!!target) {
|
|
192
|
+
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
193
|
+
}
|
|
194
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
280
195
|
}
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
boardWithDeadEntityHero.globalInfo.UndeadAttackBonus += attackBonus;
|
|
290
|
-
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, attackBonus, 0, gameState, reference_data_1.Race[reference_data_1.Race.UNDEAD]);
|
|
291
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
292
|
-
}
|
|
293
|
-
break;
|
|
294
|
-
case "TB_BaconShop_HERO_17_Buddy":
|
|
295
|
-
case "TB_BaconShop_HERO_17_Buddy_G":
|
|
296
|
-
const squirrelDamage = deadEntity.cardId === "TB_BaconShop_HERO_17_Buddy_G" ? 4 : 2;
|
|
297
|
-
for (let i = 0; i < multiplier; i++) {
|
|
298
|
-
const numberOfDeadMechsThisCombat = gameState.sharedState.deaths
|
|
299
|
-
.filter((entity) => entity.friendly === deadEntity.friendly)
|
|
300
|
-
.filter((entity) => (0, utils_2.hasCorrectTribe)(entity, boardWithDeadEntityHero, reference_data_1.Race.MECH, gameState.allCards)).length;
|
|
301
|
-
for (let j = 0; j < numberOfDeadMechsThisCombat; j++) {
|
|
302
|
-
(0, attack_1.dealDamageToRandomEnemy)(otherBoard, otherBoardHero, deadEntity, squirrelDamage, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
196
|
+
break;
|
|
197
|
+
case "BG21_001_G":
|
|
198
|
+
for (let i = 0; i < multiplier; i++) {
|
|
199
|
+
const target = (0, utils_2.grantRandomStats)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 12, 12, reference_data_1.Race.BEAST, true, gameState);
|
|
200
|
+
if (!!target) {
|
|
201
|
+
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
202
|
+
}
|
|
203
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
303
204
|
}
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
for (let j = 0; j < kaboomLoops; j++) {
|
|
315
|
-
(0, attack_1.dealDamageToRandomEnemy)(otherBoard, otherBoardHero, deadEntity, baseDamage, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
205
|
+
break;
|
|
206
|
+
case "BG25_022":
|
|
207
|
+
case "BG25_022_G":
|
|
208
|
+
const scarletMultiplier = deadEntityCardId === "BG25_022_G" ? 2 : 1;
|
|
209
|
+
for (let i = 0; i < multiplier; i++) {
|
|
210
|
+
const target = (0, utils_2.grantRandomStats)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, scarletMultiplier * 1, scarletMultiplier * 2, reference_data_1.Race.UNDEAD, false, gameState);
|
|
211
|
+
if (!!target) {
|
|
212
|
+
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
213
|
+
}
|
|
214
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
316
215
|
}
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
216
|
+
break;
|
|
217
|
+
case "BG25_007":
|
|
218
|
+
case "BG25_007_G":
|
|
219
|
+
const anubarakMultiplier = deadEntityCardId === "BG25_007_G" ? 2 : 1;
|
|
220
|
+
const attackBonus = anubarakMultiplier * 1;
|
|
221
|
+
for (let i = 0; i < multiplier; i++) {
|
|
222
|
+
boardWithDeadEntityHero.globalInfo.UndeadAttackBonus += attackBonus;
|
|
223
|
+
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, attackBonus, 0, gameState, reference_data_1.Race[reference_data_1.Race.UNDEAD]);
|
|
224
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
225
|
+
}
|
|
226
|
+
break;
|
|
227
|
+
case "TB_BaconShop_HERO_17_Buddy":
|
|
228
|
+
case "TB_BaconShop_HERO_17_Buddy_G":
|
|
229
|
+
const squirrelDamage = deadEntity.cardId === "TB_BaconShop_HERO_17_Buddy_G" ? 4 : 2;
|
|
230
|
+
for (let i = 0; i < multiplier; i++) {
|
|
231
|
+
const numberOfDeadMechsThisCombat = gameState.sharedState.deaths
|
|
232
|
+
.filter((entity) => entity.friendly === deadEntity.friendly)
|
|
233
|
+
.filter((entity) => (0, utils_2.hasCorrectTribe)(entity, boardWithDeadEntityHero, reference_data_1.Race.MECH, gameState.allCards)).length;
|
|
234
|
+
for (let j = 0; j < numberOfDeadMechsThisCombat; j++) {
|
|
235
|
+
(0, attack_1.dealDamageToRandomEnemy)(otherBoard, otherBoardHero, deadEntity, squirrelDamage, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
331
236
|
}
|
|
237
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
332
238
|
}
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
(0,
|
|
239
|
+
break;
|
|
240
|
+
case "BG_BOT_606":
|
|
241
|
+
case "TB_BaconUps_028":
|
|
242
|
+
const kaboomLoops = deadEntity.cardId === "TB_BaconUps_028" ? 2 : 1;
|
|
243
|
+
const baseDamage = 4 +
|
|
244
|
+
boardWithDeadEntityHero.trinkets.filter((t) => t.cardId === "BG30_MagicItem_803").length *
|
|
245
|
+
10;
|
|
246
|
+
for (let i = 0; i < multiplier; i++) {
|
|
247
|
+
for (let j = 0; j < kaboomLoops; j++) {
|
|
248
|
+
(0, attack_1.dealDamageToRandomEnemy)(otherBoard, otherBoardHero, deadEntity, baseDamage, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
249
|
+
}
|
|
250
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
345
251
|
}
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
const damage = deadEntityCardId === "TB_BaconUps_118" ? 2 : 1;
|
|
363
|
-
for (let i = 0; i < multiplier; i++) {
|
|
364
|
-
const minionsToDamage = [...otherBoard, ...boardWithDeadEntity];
|
|
365
|
-
for (const target of minionsToDamage) {
|
|
366
|
-
const isSameSide = target.friendly === deadEntity.friendly;
|
|
367
|
-
const board = isSameSide ? boardWithDeadEntity : otherBoard;
|
|
368
|
-
const hero = isSameSide ? boardWithDeadEntityHero : otherBoardHero;
|
|
369
|
-
(0, attack_1.dealDamageToMinion)(target, board, hero, deadEntity, damage, isSameSide ? otherBoard : boardWithDeadEntity, isSameSide ? otherBoardHero : boardWithDeadEntityHero, gameState);
|
|
252
|
+
break;
|
|
253
|
+
case "BG29_843":
|
|
254
|
+
case "BG29_843_G":
|
|
255
|
+
const fireDancerLoops = deadEntity.cardId === "BG29_843_G" ? 2 : 1;
|
|
256
|
+
for (let i = 0; i < multiplier; i++) {
|
|
257
|
+
for (let j = 0; j < fireDancerLoops; j++) {
|
|
258
|
+
const minionsToDamage = [...otherBoard, ...boardWithDeadEntity];
|
|
259
|
+
for (const target of minionsToDamage) {
|
|
260
|
+
const isSameSide = target.friendly === deadEntity.friendly;
|
|
261
|
+
const board = isSameSide ? boardWithDeadEntity : otherBoard;
|
|
262
|
+
const hero = isSameSide ? boardWithDeadEntityHero : otherBoardHero;
|
|
263
|
+
(0, attack_1.dealDamageToMinion)(target, board, hero, deadEntity, 1, isSameSide ? otherBoard : boardWithDeadEntity, isSameSide ? otherBoardHero : boardWithDeadEntityHero, gameState);
|
|
264
|
+
}
|
|
265
|
+
}
|
|
266
|
+
(0, attack_1.processMinionDeath)(boardWithDeadEntity, boardWithDeadEntityHero, otherBoard, otherBoardHero, gameState);
|
|
267
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
370
268
|
}
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
269
|
+
break;
|
|
270
|
+
case "BG28_968":
|
|
271
|
+
case "BG28_968_G":
|
|
272
|
+
const lighterFighterDamage = deadEntity.cardId === "BG28_968_G" ? 8 : 4;
|
|
273
|
+
for (let i = 0; i < multiplier; i++) {
|
|
274
|
+
for (let j = 0; j < 2; j++) {
|
|
275
|
+
const target = (0, utils_1.pickRandomLowestHealth)(otherBoard);
|
|
276
|
+
gameState.spectator.registerPowerTarget(deadEntity, target, otherBoard, boardWithDeadEntityHero, otherBoardHero);
|
|
277
|
+
(0, attack_1.dealDamageToMinion)(target, otherBoard, otherBoardHero, deadEntity, lighterFighterDamage, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
278
|
+
}
|
|
279
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
280
|
+
}
|
|
281
|
+
break;
|
|
282
|
+
case "BG25_165":
|
|
283
|
+
case "BG25_165_G":
|
|
284
|
+
const boomboxDamage = deadEntity.cardId === "BG25_165_G" ? 14 : 7;
|
|
285
|
+
for (let i = 0; i < multiplier; i++) {
|
|
286
|
+
const targets = (0, attack_1.findNearestEnemies)(boardWithDeadEntity, null, deadEntityIndexFromRight, otherBoard, 2, gameState.allCards);
|
|
287
|
+
targets.forEach((target) => {
|
|
288
|
+
(0, attack_1.dealDamageToMinion)(target, otherBoard, otherBoardHero, deadEntity, boomboxDamage, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
289
|
+
});
|
|
290
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
291
|
+
}
|
|
292
|
+
break;
|
|
293
|
+
case "BG_FP1_024":
|
|
294
|
+
case "TB_BaconUps_118":
|
|
295
|
+
const damage = deadEntityCardId === "TB_BaconUps_118" ? 2 : 1;
|
|
296
|
+
for (let i = 0; i < multiplier; i++) {
|
|
379
297
|
const minionsToDamage = [...otherBoard, ...boardWithDeadEntity];
|
|
380
298
|
for (const target of minionsToDamage) {
|
|
381
299
|
const isSameSide = target.friendly === deadEntity.friendly;
|
|
382
300
|
const board = isSameSide ? boardWithDeadEntity : otherBoard;
|
|
383
301
|
const hero = isSameSide ? boardWithDeadEntityHero : otherBoardHero;
|
|
384
|
-
(0, attack_1.dealDamageToMinion)(target, board, hero, deadEntity,
|
|
302
|
+
(0, attack_1.dealDamageToMinion)(target, board, hero, deadEntity, damage, isSameSide ? otherBoard : boardWithDeadEntity, isSameSide ? otherBoardHero : boardWithDeadEntityHero, gameState);
|
|
385
303
|
}
|
|
304
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
386
305
|
}
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
for (let i = 0; i < multiplier; i++) {
|
|
409
|
-
(0, cards_in_hand_1.addCardsInHand)(boardWithDeadEntityHero, boardWithDeadEntity, [null], gameState);
|
|
410
|
-
}
|
|
411
|
-
break;
|
|
412
|
-
case "BG26_867":
|
|
413
|
-
case "BG26_867_G":
|
|
414
|
-
for (let i = 0; i < multiplier; i++) {
|
|
415
|
-
const numberOfBloodGems = deadEntityCardId === "BG26_867_G" ? 6 : 3;
|
|
416
|
-
for (const entity of boardWithDeadEntity.filter((e) => (0, utils_2.hasCorrectTribe)(e, boardWithDeadEntityHero, reference_data_1.Race.QUILBOAR, gameState.allCards))) {
|
|
417
|
-
(0, blood_gems_1.playBloodGemsOn)(deadEntity, entity, numberOfBloodGems, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
306
|
+
break;
|
|
307
|
+
case "BG_DAL_775":
|
|
308
|
+
case "BG_DAL_775_G":
|
|
309
|
+
const loops = deadEntityCardId === "BG_DAL_775_G" ? 2 : 1;
|
|
310
|
+
for (let i = 0; i < multiplier; i++) {
|
|
311
|
+
for (let j = 0; j < loops; j++) {
|
|
312
|
+
const minionsToDamage = [...otherBoard, ...boardWithDeadEntity];
|
|
313
|
+
for (const target of minionsToDamage) {
|
|
314
|
+
const isSameSide = target.friendly === deadEntity.friendly;
|
|
315
|
+
const board = isSameSide ? boardWithDeadEntity : otherBoard;
|
|
316
|
+
const hero = isSameSide ? boardWithDeadEntityHero : otherBoardHero;
|
|
317
|
+
(0, attack_1.dealDamageToMinion)(target, board, hero, deadEntity, 3, isSameSide ? otherBoard : boardWithDeadEntity, isSameSide ? otherBoardHero : boardWithDeadEntityHero, gameState);
|
|
318
|
+
}
|
|
319
|
+
}
|
|
320
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
321
|
+
}
|
|
322
|
+
break;
|
|
323
|
+
case "BG23_318":
|
|
324
|
+
case "BG23_318_G":
|
|
325
|
+
if (deadEntity.lastAffectedByEntity) {
|
|
326
|
+
deadEntity.lastAffectedByEntity.definitelyDead = true;
|
|
418
327
|
}
|
|
419
328
|
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
329
|
+
break;
|
|
330
|
+
case "BG25_399":
|
|
331
|
+
case "BG25_399_G":
|
|
332
|
+
for (let i = 0; i < multiplier; i++) {
|
|
333
|
+
const radioQuantity = deadEntityCardId === "BG25_399_G" ? 2 : 1;
|
|
334
|
+
const radioEntities = Array(radioQuantity).fill(deadEntity.lastAffectedByEntity);
|
|
335
|
+
(0, cards_in_hand_1.addCardsInHand)(boardWithDeadEntityHero, boardWithDeadEntity, radioEntities, gameState);
|
|
336
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
337
|
+
}
|
|
338
|
+
break;
|
|
339
|
+
case "BG28_900":
|
|
340
|
+
case "BG28_900_G":
|
|
341
|
+
for (let i = 0; i < multiplier; i++) {
|
|
342
|
+
(0, cards_in_hand_1.addCardsInHand)(boardWithDeadEntityHero, boardWithDeadEntity, [null], gameState);
|
|
343
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
344
|
+
}
|
|
345
|
+
break;
|
|
346
|
+
case "BG26_867":
|
|
347
|
+
case "BG26_867_G":
|
|
348
|
+
for (let i = 0; i < multiplier; i++) {
|
|
349
|
+
const numberOfBloodGems = deadEntityCardId === "BG26_867_G" ? 6 : 3;
|
|
350
|
+
for (const entity of boardWithDeadEntity.filter((e) => (0, utils_2.hasCorrectTribe)(e, boardWithDeadEntityHero, reference_data_1.Race.QUILBOAR, gameState.allCards))) {
|
|
351
|
+
(0, blood_gems_1.playBloodGemsOn)(deadEntity, entity, numberOfBloodGems, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
431
352
|
}
|
|
353
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
432
354
|
}
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
for (let i = 0; i < multiplier; i++) {
|
|
447
|
-
const sanguineChampionStats = deadEntityCardId === "BG23_017" ? 1 : 2;
|
|
448
|
-
boardWithDeadEntityHero.globalInfo.BloodGemAttackBonus += sanguineChampionStats;
|
|
449
|
-
boardWithDeadEntityHero.globalInfo.BloodGemHealthBonus += sanguineChampionStats;
|
|
450
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
451
|
-
}
|
|
452
|
-
break;
|
|
453
|
-
case "BG26_160":
|
|
454
|
-
case "BG26_160_G":
|
|
455
|
-
for (let i = 0; i < multiplier; i++) {
|
|
456
|
-
const piperBuff = deadEntityCardId === "BG26_160" ? 1 : 2;
|
|
457
|
-
boardWithDeadEntityHero.globalInfo.BloodGemAttackBonus += piperBuff;
|
|
458
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
459
|
-
}
|
|
460
|
-
break;
|
|
461
|
-
case "BG_RLK_957":
|
|
462
|
-
for (let i = 0; i < multiplier; i++) {
|
|
463
|
-
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 2, 1, gameState, reference_data_1.Race[reference_data_1.Race.UNDEAD]);
|
|
464
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
465
|
-
}
|
|
466
|
-
break;
|
|
467
|
-
case "BG26_GIL_513":
|
|
468
|
-
for (let i = 0; i < multiplier; i++) {
|
|
469
|
-
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 1, 0, gameState, null);
|
|
470
|
-
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
471
|
-
}
|
|
472
|
-
break;
|
|
473
|
-
case "BG_ICC_099":
|
|
474
|
-
for (let i = 0; i < multiplier; i++) {
|
|
475
|
-
for (const entity of boardWithDeadEntity) {
|
|
476
|
-
(0, attack_1.dealDamageToMinion)(entity, boardWithDeadEntity, boardWithDeadEntityHero, deadEntity, 5, otherBoard, otherBoardHero, gameState);
|
|
355
|
+
break;
|
|
356
|
+
case "TB_BaconShop_HERO_41_Buddy":
|
|
357
|
+
case "TB_BaconShop_HERO_41_Buddy_G":
|
|
358
|
+
for (let i = 0; i < multiplier; i++) {
|
|
359
|
+
const numberToGild = deadEntityCardId === "TB_BaconShop_HERO_41_Buddy_G" ? 2 : 1;
|
|
360
|
+
const targetBoard = boardWithDeadEntity.filter((e) => !e.definitelyDead && e.health > 0);
|
|
361
|
+
for (let i = 0; i < Math.min(numberToGild, boardWithDeadEntity.length); i++) {
|
|
362
|
+
const rightMostMinion = targetBoard[targetBoard.length - 1 - i];
|
|
363
|
+
if (rightMostMinion) {
|
|
364
|
+
(0, golden_1.makeMinionGolden)(rightMostMinion, deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, gameState);
|
|
365
|
+
}
|
|
366
|
+
}
|
|
367
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
477
368
|
}
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
(0
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
for (let i = 0; i < multiplier; i++) {
|
|
525
|
-
for (let j = 0; j < mummifierBuff; j++) {
|
|
526
|
-
const targets = boardWithDeadEntity
|
|
527
|
-
.filter((e) => e.cardId !== "BG28_309" &&
|
|
528
|
-
e.cardId !== "BG28_309_G")
|
|
529
|
-
.filter((e) => !e.reborn)
|
|
530
|
-
.filter((e) => (0, utils_2.hasCorrectTribe)(e, boardWithDeadEntityHero, reference_data_1.Race.UNDEAD, gameState.allCards));
|
|
531
|
-
const target = (0, utils_1.pickRandom)(targets);
|
|
532
|
-
if (target) {
|
|
533
|
-
target.reborn = true;
|
|
534
|
-
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
369
|
+
break;
|
|
370
|
+
case "BG26_360":
|
|
371
|
+
case "BG26_360_G":
|
|
372
|
+
const statsScourfin = deadEntityCardId === "BG26_360_G" ? 10 : 5;
|
|
373
|
+
for (let i = 0; i < multiplier; i++) {
|
|
374
|
+
(0, utils_2.grantRandomStats)(deadEntity, boardWithDeadEntityHero.hand.filter((e) => {
|
|
375
|
+
var _a;
|
|
376
|
+
return ((_a = gameState.allCards.getCard(e.cardId).type) === null || _a === void 0 ? void 0 : _a.toUpperCase()) ===
|
|
377
|
+
reference_data_1.CardType[reference_data_1.CardType.MINION];
|
|
378
|
+
}), boardWithDeadEntityHero, statsScourfin, statsScourfin, null, true, gameState);
|
|
379
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
380
|
+
}
|
|
381
|
+
break;
|
|
382
|
+
case "BG23_017":
|
|
383
|
+
case "BG23_017_G":
|
|
384
|
+
for (let i = 0; i < multiplier; i++) {
|
|
385
|
+
const sanguineChampionStats = deadEntityCardId === "BG23_017" ? 1 : 2;
|
|
386
|
+
boardWithDeadEntityHero.globalInfo.BloodGemAttackBonus += sanguineChampionStats;
|
|
387
|
+
boardWithDeadEntityHero.globalInfo.BloodGemHealthBonus += sanguineChampionStats;
|
|
388
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
389
|
+
}
|
|
390
|
+
break;
|
|
391
|
+
case "BG26_160":
|
|
392
|
+
case "BG26_160_G":
|
|
393
|
+
for (let i = 0; i < multiplier; i++) {
|
|
394
|
+
const piperBuff = deadEntityCardId === "BG26_160" ? 1 : 2;
|
|
395
|
+
boardWithDeadEntityHero.globalInfo.BloodGemAttackBonus += piperBuff;
|
|
396
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
397
|
+
}
|
|
398
|
+
break;
|
|
399
|
+
case "BG_RLK_957":
|
|
400
|
+
for (let i = 0; i < multiplier; i++) {
|
|
401
|
+
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 2, 1, gameState, reference_data_1.Race[reference_data_1.Race.UNDEAD]);
|
|
402
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
403
|
+
}
|
|
404
|
+
break;
|
|
405
|
+
case "BG26_GIL_513":
|
|
406
|
+
for (let i = 0; i < multiplier; i++) {
|
|
407
|
+
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, 1, 0, gameState, null);
|
|
408
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
409
|
+
}
|
|
410
|
+
break;
|
|
411
|
+
case "BG_ICC_099":
|
|
412
|
+
for (let i = 0; i < multiplier; i++) {
|
|
413
|
+
for (const entity of boardWithDeadEntity) {
|
|
414
|
+
(0, attack_1.dealDamageToMinion)(entity, boardWithDeadEntity, boardWithDeadEntityHero, deadEntity, 5, otherBoard, otherBoardHero, gameState);
|
|
535
415
|
}
|
|
416
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
536
417
|
}
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
const scraperCardsToAdd = [];
|
|
545
|
-
for (let i = 0; i < scraperToAddQuantity; i++) {
|
|
546
|
-
scraperCardsToAdd.push((0, utils_1.pickRandom)(gameState.cardsData.scrapScraperSpawns));
|
|
418
|
+
break;
|
|
419
|
+
case "BG27_006":
|
|
420
|
+
case "BG27_006_G":
|
|
421
|
+
for (let i = 0; i < multiplier; i++) {
|
|
422
|
+
const witheredSpearhideCardsToAdd = Array(deadEntity.cardId === "BG27_006_G" ? 2 : 1).fill("BG20_GEM");
|
|
423
|
+
(0, cards_in_hand_1.addCardsInHand)(boardWithDeadEntityHero, boardWithDeadEntity, witheredSpearhideCardsToAdd, gameState);
|
|
424
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
547
425
|
}
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
for (let i = 0; i < multiplier; i++) {
|
|
555
|
-
const conjurerToAddQuantity = deadEntity.cardId === "BG29_862_G" ? 2 : 1;
|
|
556
|
-
const conjurerCardsToAdd = [];
|
|
557
|
-
for (let i = 0; i < conjurerToAddQuantity; i++) {
|
|
558
|
-
conjurerCardsToAdd.push((0, utils_1.pickRandom)(gameState.cardsData.battlecryMinions));
|
|
426
|
+
break;
|
|
427
|
+
case "BG26_055":
|
|
428
|
+
case "BG26_055_G":
|
|
429
|
+
for (let i = 0; i < multiplier; i++) {
|
|
430
|
+
applyRecurringNightmareDeathrattleEffect(boardWithDeadEntity, boardWithDeadEntityHero, deadEntity, deadEntityCardId === "BG26_055_G", gameState.allCards, gameState.spectator, gameState.sharedState);
|
|
431
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
559
432
|
}
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
433
|
+
break;
|
|
434
|
+
case "BG27_080":
|
|
435
|
+
case "BG27_080_G":
|
|
436
|
+
const motleyBuff = deadEntity.cardId === "BG27_080_G" ? 2 : 1;
|
|
437
|
+
for (let i = 0; i < multiplier; i++) {
|
|
438
|
+
(0, utils_2.grantStatsToMinionsOfEachType)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, motleyBuff * 2, motleyBuff * 1, gameState);
|
|
439
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
440
|
+
}
|
|
441
|
+
break;
|
|
442
|
+
case "BG28_304":
|
|
443
|
+
case "BG28_304_G":
|
|
444
|
+
const moroesBuffAtk = deadEntity.cardId === "BG28_304_G" ? 4 : 2;
|
|
445
|
+
const moroesBuffHealth = deadEntity.cardId === "BG28_304_G" ? 8 : 4;
|
|
446
|
+
for (let i = 0; i < multiplier; i++) {
|
|
447
|
+
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, moroesBuffAtk, moroesBuffHealth, gameState, reference_data_1.Race[reference_data_1.Race.UNDEAD]);
|
|
448
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
449
|
+
}
|
|
450
|
+
break;
|
|
451
|
+
case "BG28_306":
|
|
452
|
+
case "BG28_306_G":
|
|
453
|
+
const steadfastSpiritBuff = deadEntity.cardId === "BG28_306_G" ? 2 : 1;
|
|
454
|
+
for (let i = 0; i < multiplier; i++) {
|
|
455
|
+
(0, utils_2.addStatsToBoard)(deadEntity, boardWithDeadEntity, boardWithDeadEntityHero, steadfastSpiritBuff, steadfastSpiritBuff, gameState);
|
|
456
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
457
|
+
}
|
|
458
|
+
break;
|
|
459
|
+
case "BG28_309":
|
|
460
|
+
case "BG28_309_G":
|
|
461
|
+
const mummifierBuff = deadEntity.cardId === "BG28_309_G" ? 2 : 1;
|
|
462
|
+
for (let i = 0; i < multiplier; i++) {
|
|
463
|
+
for (let j = 0; j < mummifierBuff; j++) {
|
|
464
|
+
const targets = boardWithDeadEntity
|
|
465
|
+
.filter((e) => e.cardId !== "BG28_309" &&
|
|
466
|
+
e.cardId !== "BG28_309_G")
|
|
467
|
+
.filter((e) => !e.reborn)
|
|
468
|
+
.filter((e) => (0, utils_2.hasCorrectTribe)(e, boardWithDeadEntityHero, reference_data_1.Race.UNDEAD, gameState.allCards));
|
|
469
|
+
const target = (0, utils_1.pickRandom)(targets);
|
|
470
|
+
if (target) {
|
|
471
|
+
(0, reborn_1.updateReborn)(target, true, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, gameState);
|
|
472
|
+
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
473
|
+
}
|
|
575
474
|
}
|
|
475
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
576
476
|
}
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
const targetBoard = [...boardWithDeadEntity];
|
|
586
|
-
for (const entity of targetBoard) {
|
|
587
|
-
(0, stats_1.modifyStats)(entity, 0, 1, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
588
|
-
(_c = gameState.spectator) === null || _c === void 0 ? void 0 : _c.registerPowerTarget(deadEntity, entity, boardWithDeadEntity, null, null);
|
|
477
|
+
break;
|
|
478
|
+
case "BG26_148":
|
|
479
|
+
case "BG26_148_G":
|
|
480
|
+
for (let i = 0; i < multiplier; i++) {
|
|
481
|
+
const scraperToAddQuantity = deadEntity.cardId === "BG26_148_G" ? 2 : 1;
|
|
482
|
+
const scraperCardsToAdd = [];
|
|
483
|
+
for (let i = 0; i < scraperToAddQuantity; i++) {
|
|
484
|
+
scraperCardsToAdd.push((0, utils_1.pickRandom)(gameState.cardsData.scrapScraperSpawns));
|
|
589
485
|
}
|
|
590
|
-
|
|
591
|
-
|
|
486
|
+
(0, cards_in_hand_1.addCardsInHand)(boardWithDeadEntityHero, boardWithDeadEntity, scraperCardsToAdd, gameState);
|
|
487
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
488
|
+
}
|
|
489
|
+
break;
|
|
490
|
+
case "BG29_862":
|
|
491
|
+
case "BG29_862_G":
|
|
492
|
+
for (let i = 0; i < multiplier; i++) {
|
|
493
|
+
const conjurerToAddQuantity = deadEntity.cardId === "BG29_862_G" ? 2 : 1;
|
|
494
|
+
const conjurerCardsToAdd = [];
|
|
495
|
+
for (let i = 0; i < conjurerToAddQuantity; i++) {
|
|
496
|
+
conjurerCardsToAdd.push((0, utils_1.pickRandom)(gameState.cardsData.battlecryMinions));
|
|
592
497
|
}
|
|
498
|
+
(0, cards_in_hand_1.addCardsInHand)(boardWithDeadEntityHero, boardWithDeadEntity, conjurerCardsToAdd, gameState);
|
|
499
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
593
500
|
}
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
501
|
+
break;
|
|
502
|
+
case "BG25_HERO_103_Buddy":
|
|
503
|
+
case "BG25_HERO_103_Buddy_G":
|
|
504
|
+
for (let i = 0; i < multiplier; i++) {
|
|
505
|
+
const loops = deadEntity.cardId === "BG25_HERO_103_Buddy_G" ? 2 : 1;
|
|
506
|
+
for (let j = 0; j < loops; j++) {
|
|
507
|
+
const atkBuff = deadEntity.attack;
|
|
508
|
+
const healthBuff = deadEntity.maxHealth;
|
|
509
|
+
const target = (0, utils_1.pickRandom)(boardWithDeadEntity.filter((e) => e.entityId !== deadEntity.entityId));
|
|
510
|
+
if (target) {
|
|
511
|
+
(0, stats_1.modifyStats)(target, atkBuff, healthBuff, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
512
|
+
gameState.spectator.registerPowerTarget(deadEntity, target, boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero);
|
|
513
|
+
}
|
|
514
|
+
}
|
|
515
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
516
|
+
}
|
|
517
|
+
break;
|
|
518
|
+
case "BG29_808":
|
|
519
|
+
case "BG29_808_G":
|
|
520
|
+
const spikedSaviorLoops = deadEntity.cardId === "BG29_808_G" ? 2 : 1;
|
|
606
521
|
for (let i = 0; i < multiplier; i++) {
|
|
522
|
+
for (let j = 0; j < spikedSaviorLoops; j++) {
|
|
523
|
+
const targetBoard = [...boardWithDeadEntity];
|
|
524
|
+
for (const entity of targetBoard) {
|
|
525
|
+
(0, stats_1.modifyStats)(entity, 0, 1, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
526
|
+
(_c = gameState.spectator) === null || _c === void 0 ? void 0 : _c.registerPowerTarget(deadEntity, entity, boardWithDeadEntity, null, null);
|
|
527
|
+
}
|
|
528
|
+
for (const entity of targetBoard) {
|
|
529
|
+
(0, attack_1.dealDamageToMinion)(entity, boardWithDeadEntity, boardWithDeadEntityHero, deadEntity, 1, otherBoard, otherBoardHero, gameState);
|
|
530
|
+
}
|
|
531
|
+
}
|
|
607
532
|
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
608
533
|
}
|
|
609
|
-
|
|
610
|
-
|
|
534
|
+
break;
|
|
535
|
+
case "BG31_821":
|
|
536
|
+
case "BG31_821_G":
|
|
537
|
+
for (let i = 0; i < multiplier; i++) {
|
|
538
|
+
boardWithDeadEntityHero.globalInfo.PirateAttackBonus +=
|
|
539
|
+
deadEntity.cardId === "BG31_821_G" ? 10 : 5;
|
|
540
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
541
|
+
}
|
|
542
|
+
break;
|
|
543
|
+
default:
|
|
544
|
+
if ((0, utils_2.hasMechanic)(gameState.allCards.getCard(deadEntity.cardId), reference_data_1.GameTag[reference_data_1.GameTag.DEATHRATTLE])) {
|
|
545
|
+
for (let i = 0; i < multiplier; i++) {
|
|
546
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
547
|
+
}
|
|
548
|
+
}
|
|
549
|
+
break;
|
|
550
|
+
}
|
|
611
551
|
}
|
|
612
552
|
}
|
|
613
553
|
for (const enchantment of enchantments) {
|
|
554
|
+
const deathrattleImpl = _card_mappings_1.cardMappings[enchantment.cardId];
|
|
555
|
+
if ((0, card_interface_1.hasDeathrattleEnchantmentEffect)(deathrattleImpl)) {
|
|
556
|
+
for (let i = 0; i < multiplier; i++) {
|
|
557
|
+
deathrattleImpl.deathrattleEnchantmentEffect(enchantment, deathrattleTriggeredInput);
|
|
558
|
+
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
559
|
+
}
|
|
560
|
+
}
|
|
614
561
|
switch (enchantment.cardId) {
|
|
615
562
|
case "BG30_MagicItem_917e":
|
|
616
|
-
(0
|
|
563
|
+
for (let i = 0; i < multiplier; i++) {
|
|
564
|
+
(0, cards_in_hand_1.addCardsInHand)(boardWithDeadEntityHero, boardWithDeadEntity, [null], gameState);
|
|
565
|
+
}
|
|
617
566
|
break;
|
|
618
567
|
case "BG30_MagicItem_411e":
|
|
619
|
-
(0
|
|
568
|
+
for (let i = 0; i < multiplier; i++) {
|
|
569
|
+
(0, cards_in_hand_1.addCardsInHand)(boardWithDeadEntityHero, boardWithDeadEntity, ["BG20_GEM"], gameState);
|
|
570
|
+
}
|
|
620
571
|
break;
|
|
621
572
|
case "BG21_000e":
|
|
622
573
|
case "BG21_000_Ge":
|
|
@@ -637,7 +588,7 @@ const handleDeathrattleEffects = (boardWithDeadEntity, boardWithDeadEntityHero,
|
|
|
637
588
|
break;
|
|
638
589
|
case "BG22_HERO_001_Buddy_e3":
|
|
639
590
|
for (let i = 0; i < multiplier; i++) {
|
|
640
|
-
(0, exports.applyWaterInvocationEnchantment)(boardWithDeadEntity, boardWithDeadEntityHero, deadEntity, deadEntity, gameState);
|
|
591
|
+
(0, exports.applyWaterInvocationEnchantment)(boardWithDeadEntity, boardWithDeadEntityHero, otherBoardHero, deadEntity, deadEntity, gameState);
|
|
641
592
|
(0, deathrattle_on_trigger_1.onDeathrattleTriggered)(deathrattleTriggeredInput);
|
|
642
593
|
}
|
|
643
594
|
break;
|
|
@@ -661,13 +612,13 @@ const applyLightningInvocationEnchantment = (boardWithDeadEntity, boardWithDeadE
|
|
|
661
612
|
}
|
|
662
613
|
};
|
|
663
614
|
exports.applyLightningInvocationEnchantment = applyLightningInvocationEnchantment;
|
|
664
|
-
const applyWaterInvocationEnchantment = (boardWithDeadEntity, boardWithDeadEntityHero, deadEntity, sourceEntity, gameState) => {
|
|
615
|
+
const applyWaterInvocationEnchantment = (boardWithDeadEntity, boardWithDeadEntityHero, otherHero, deadEntity, sourceEntity, gameState) => {
|
|
665
616
|
const multiplier = (deadEntity === null || deadEntity === void 0 ? void 0 : deadEntity.cardId) === "BG22_HERO_001_Buddy_G" ? 2 : 1;
|
|
666
617
|
for (let i = 0; i < multiplier; i++) {
|
|
667
618
|
const validBoard = boardWithDeadEntity.filter((e) => e.health > 0 && !e.definitelyDead);
|
|
668
619
|
const target = validBoard[validBoard.length - 1];
|
|
669
620
|
if (!!target) {
|
|
670
|
-
target
|
|
621
|
+
(0, taunt_1.updateTaunt)(target, true, boardWithDeadEntity, boardWithDeadEntityHero, otherHero, gameState);
|
|
671
622
|
(0, stats_1.modifyStats)(target, 0, 3, boardWithDeadEntity, boardWithDeadEntityHero, gameState);
|
|
672
623
|
gameState.spectator.registerPowerTarget(sourceEntity, target, boardWithDeadEntity, null, null);
|
|
673
624
|
}
|
|
@@ -960,7 +911,7 @@ const rememberDeathrattles = (fish, deadEntities, cardsData, allCards, sharedSta
|
|
|
960
911
|
timing: sharedState.currentEntityId++,
|
|
961
912
|
});
|
|
962
913
|
})
|
|
963
|
-
.filter((enchantment) => simulate_bgs_battle_1.
|
|
914
|
+
.filter((enchantment) => (0, simulate_bgs_battle_1.isValidDeathrattleEnchantment)(enchantment.cardId));
|
|
964
915
|
const deadEntityRememberedDeathrattles = (_a = deadEntities
|
|
965
916
|
.filter((e) => { var _a; return !!((_a = e.rememberedDeathrattles) === null || _a === void 0 ? void 0 : _a.length); })
|
|
966
917
|
.filter((e) => e.entityId !== fish.rebornFromEntityId)
|