"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getEffectiveTribesEnum = exports.getTribesForInclusion = exports.getEffectiveTribes = exports.isBaconGhost = exports.getBuddy = exports.getHeroPower = exports.getReferenceTribeCardId = exports.getTribeIcon = exports.getTribeName = exports.normalizeMinionCardId = exports.normalizeHeroCardId = exports.isBattlegroundsDuo = exports.isBattlegrounds = exports.defaultStartingHp = exports.BUDDIES_TRIBE_REQUIREMENTS = exports.NON_DISCOVERABLE_BUDDIES = exports.NON_BUYABLE_MINION_IDS = exports.TOTAL_RACES_IN_GAME = exports.ALL_BG_RACES = void 0;
const public_api_1 = require("../public-api");
const hs_utils_1 = require("./hs-utils");
exports.ALL_BG_RACES = [
    public_api_1.Race.BEAST,
    public_api_1.Race.DEMON,
    public_api_1.Race.DRAGON,
    public_api_1.Race.MECH,
    public_api_1.Race.MURLOC,
    public_api_1.Race.PIRATE,
    public_api_1.Race.ELEMENTAL,
    public_api_1.Race.QUILBOAR,
    public_api_1.Race.NAGA,
    public_api_1.Race.UNDEAD,
];
exports.TOTAL_RACES_IN_GAME = 5;
exports.NON_BUYABLE_MINION_IDS = [
    public_api_1.CardIds.Cuddlgam_TB_BaconShop_HP_033t_SKIN_A,
    public_api_1.CardIds.Cuddlgam_TB_BaconShop_HP_033t_SKIN_A_G,
    public_api_1.CardIds.AbominableAmalgam_TB_BaconShop_HP_033t_SKIN_D,
    public_api_1.CardIds.AbominableAmalgam_TB_BaconShop_HP_033t_SKIN_D_G,
    public_api_1.CardIds.BookEatingAmalgam_TB_BaconShop_HP_033t_SKIN_B,
    public_api_1.CardIds.BookEatingAmalgam_TB_BaconShop_HP_033t_SKIN_B_G,
    public_api_1.CardIds.AvatarOfNzoth_FishOfNzothToken,
    public_api_1.CardIds.FishOfNzoth,
    public_api_1.CardIds.CattlecarpOfNzoth_TB_BaconShop_HP_105t_SKIN_A,
    public_api_1.CardIds.CattlecarpOfNzoth_TB_BaconShop_HP_105t_SKIN_A_G,
    public_api_1.CardIds.SnakeTrap_SnakeLegacyToken,
    public_api_1.CardIds.SnakeTrap_SnakeVanillaToken,
    public_api_1.CardIds.ImprovedSnakeTrap_SnakeToken,
    public_api_1.CardIds.ElementEarth_StoneElementalToken,
    public_api_1.CardIds.BabyKrush_DevilsaurToken,
    public_api_1.CardIds.Devilsaur,
    public_api_1.CardIds.FriendOfAFriend_BG22_404,
    public_api_1.CardIds.FriendOfAFriend_BG22_404_G,
    public_api_1.CardIds.Onyxia_OnyxianWhelpToken,
    public_api_1.CardIds.MurlocWarleaderCore,
    public_api_1.CardIds.MurlocWarleaderVanilla,
    public_api_1.CardIds.Tentacular_OzumatsTentacleToken_BG23_HERO_201pt,
    public_api_1.CardIds.Tentacular_OzumatsTentacleToken_BG23_HERO_201pt2,
    public_api_1.CardIds.Tentacular_OzumatsTentacleToken_BG23_HERO_201pt3,
    public_api_1.CardIds.Tentacular_OzumatsTentacleToken_BG23_HERO_201pt4,
    public_api_1.CardIds.Tentacular_OzumatsTentacleToken_BG23_HERO_201pt5,
    public_api_1.CardIds.Tentacular_OzumatsTentacleToken_BG23_HERO_201pt6,
    public_api_1.CardIds.EmperorCobraLegacy_BG_EX1_170,
    public_api_1.CardIds.EmperorCobraLegacy_BG_EX1_170_G,
    public_api_1.CardIds.EmperorCobraLegacy_EX1_170,
    public_api_1.CardIds.SnakeLegacyToken,
    public_api_1.CardIds.SnakeLegacy,
    public_api_1.CardIds.ElementEarth_StoneElementalToken,
    public_api_1.CardIds.BolvarFireblood_CORE_ICC_858,
    public_api_1.CardIds.BolvarFireblood_ICC_858,
    public_api_1.CardIds.HandlessForsaken_HelpingHandToken_BG25_010t,
    public_api_1.CardIds.HandlessForsaken_HelpingHandToken_BG25_010_Gt,
    public_api_1.CardIds.GeneralDrakkisath_SmolderwingToken_BG25_309t,
    public_api_1.CardIds.GeneralDrakkisath_SmolderwingToken_BG25_309_Gt,
    public_api_1.CardIds.MechaJaraxxus_RustedReggieToken,
    public_api_1.CardIds.MechaJaraxxus_MagtheridonPrimeToken,
    public_api_1.CardIds.MechaJaraxxus_BaltharakToken,
    public_api_1.CardIds.RustedReggie,
    public_api_1.CardIds.MagtheridonPrime,
    public_api_1.CardIds.Baltharak,
    public_api_1.CardIds.Shudderskull_TB_BaconShop_HP_022t_SKIN_C,
    public_api_1.CardIds.Shudderskull_TB_BaconShop_HP_022t_SKIN_C_G,
    public_api_1.CardIds.OzumatsTentacle_BG23_HERO_201pt_SKIN_A,
    public_api_1.CardIds.OzumatsTentacle_BG23_HERO_201pt_SKIN_A_G,
    public_api_1.CardIds.Manasaber_CublingToken_BG26_800t,
    public_api_1.CardIds.Manasaber_CublingToken_BG26_800_Gt,
    public_api_1.CardIds.TentacleOfOctosariToken_BG26_803t,
    public_api_1.CardIds.TentacleOfOctosariToken_BG26_803_Gt,
    public_api_1.CardIds.OozelingGladiator_SlimyShieldToken_BG27_002t,
    public_api_1.CardIds.MechanizedGiftHorse_MechorseToken_BG27_008_Gt,
    public_api_1.CardIds.MechanizedGiftHorse_MechaponyToken_BG27_008t2,
    public_api_1.CardIds.MechanizedGiftHorse_MechorseToken_BG27_008_Gt,
    public_api_1.CardIds.MechanizedGiftHorse_MechaponyToken_BG27_008_Gt2,
    public_api_1.CardIds.TavernTier2,
    public_api_1.CardIds.TavernTier3,
    public_api_1.CardIds.TavernTier4,
    public_api_1.CardIds.TavernTier5,
    public_api_1.CardIds.TavernTier6,
    public_api_1.CardIds.TavernTier7_TB_BaconShopTechUp07_Button,
    public_api_1.CardIds.TombPillager_WON_340,
    public_api_1.CardIds.MechanizedGiftHorse_MechorseToken_BG27_008t,
    public_api_1.CardIds.MechanizedGiftHorse_MechorseToken_BG27_008_Gt,
    public_api_1.CardIds.StableAmalgamation_TotallyNormalHorseToken_BG28_Reward_518t,
    public_api_1.CardIds.TotallyNormalHorse_BG28_Reward_518t_G,
    public_api_1.CardIds.BoonOfBeetles_BeetleToken_BG28_603t,
    public_api_1.CardIds.Beetle_BG28_603t_G,
    public_api_1.CardIds.ToxicTumbleweed_TumblingAssassinToken_BG28_641t,
    public_api_1.CardIds.TumblingAssassin_BG28_641t_G,
    public_api_1.CardIds.SilverGoose_SilverFledglingToken_BG29_801t,
    public_api_1.CardIds.SilverGoose_SilverFledglingToken_BG29_801_Gt,
    public_api_1.CardIds.ReplicatingMenace_MicrobotToken_BG_BOT_312t,
    public_api_1.CardIds.ReplicatingMenace_MicrobotToken_TB_BaconUps_032t,
    public_api_1.CardIds.TheUninvitedGuest_ShadowToken_BG29_875t,
    public_api_1.CardIds.TheUninvitedGuest_ShadowToken_BG29_875_Gt,
];
exports.NON_DISCOVERABLE_BUDDIES = [
    public_api_1.CardIds.SpiritRaptor_BG22_HERO_001_Buddy,
    public_api_1.CardIds.RagingContender_TB_BaconShop_HERO_67_Buddy,
    public_api_1.CardIds.CaptainFairmount_BG21_HERO_000_Buddy,
    public_api_1.CardIds.FlightTrainer_BG20_HERO_283_Buddy,
    public_api_1.CardIds.JandicesApprentice_TB_BaconShop_HERO_71_Buddy,
    public_api_1.CardIds.CrimsonHandCenturion_TB_BaconShop_HERO_60_Buddy,
    public_api_1.CardIds.CrazyMonkey_TB_BaconShop_HERO_38_Buddy,
    public_api_1.CardIds.ShadowWarden_TB_BaconShop_HERO_62_Buddy,
    public_api_1.CardIds.NexusLord_TB_BaconShop_HERO_58_Buddy,
    public_api_1.CardIds.LeiFlamepaw_BG20_HERO_202_Buddy,
    public_api_1.CardIds.Watfin_BG23_HERO_303_Buddy,
    public_api_1.CardIds.NightmareEctoplasm_BG20_HERO_301_Buddy,
    public_api_1.CardIds.ManyWhelps_BG22_HERO_305_Buddy,
    public_api_1.CardIds.Tamuzo_BG23_HERO_201_Buddy,
    public_api_1.CardIds.MaxwellMightySteed_TB_BaconShop_HERO_40_Buddy,
    public_api_1.CardIds.Crabby_BG22_HERO_000_Buddy,
    public_api_1.CardIds.Mishmash_TB_BaconShop_HERO_33_Buddy,
    public_api_1.CardIds.PigeonLord_TB_BaconShop_HERO_12_Buddy,
    public_api_1.CardIds.VardensAquarrior_BG22_HERO_004_Buddy,
    public_api_1.CardIds.AcolyteOfYoggSaron_TB_BaconShop_HERO_35_Buddy,
    public_api_1.CardIds.SubmersibleChef_BG22_HERO_201_Buddy,
];
exports.BUDDIES_TRIBE_REQUIREMENTS = [
    {
        buddy: public_api_1.CardIds.Vaelastrasz_TB_BaconShop_HERO_56_Buddy,
        tribe: public_api_1.Race.DRAGON,
    },
    {
        buddy: public_api_1.CardIds.DeathsHeadSage_BG20_HERO_103_Buddy,
        tribe: public_api_1.Race.QUILBOAR,
    },
    {
        buddy: public_api_1.CardIds.SparkfinSoothsayer_TB_BaconShop_HERO_55_Buddy,
        tribe: public_api_1.Race.MURLOC,
    },
    {
        buddy: public_api_1.CardIds.SubScrubber_BG22_HERO_200_Buddy,
        tribe: public_api_1.Race.MECH,
    },
    {
        buddy: public_api_1.CardIds.CoilfangElite_BG23_HERO_304_Buddy,
        tribe: public_api_1.Race.NAGA,
    },
    {
        buddy: public_api_1.CardIds.Kilrek_TB_BaconShop_HERO_37_Buddy,
        tribe: public_api_1.Race.DEMON,
    },
    {
        buddy: public_api_1.CardIds.ElementiumSquirrelBomb_TB_BaconShop_HERO_17_Buddy,
        tribe: public_api_1.Race.MECH,
    },
    {
        buddy: public_api_1.CardIds.TuskarrRaider_TB_BaconShop_HERO_18_Buddy,
        tribe: public_api_1.Race.PIRATE,
    },
    {
        buddy: public_api_1.CardIds.Festergut_BG25_HERO_100_Buddy,
        tribe: public_api_1.Race.UNDEAD,
    },
    {
        buddy: public_api_1.CardIds.ImperialDefender_BG22_HERO_007_Buddy,
        tribe: public_api_1.Race.NAGA,
    },
    {
        buddy: public_api_1.CardIds.ValithriaDreamwalker_TB_BaconShop_HERO_53_Buddy,
        tribe: public_api_1.Race.DRAGON,
    },
];
const defaultStartingHp = (gameType, heroCardId, allCards) => {
    if (exports.isBattlegrounds(gameType)) {
        const normalized = exports.normalizeHeroCardId(heroCardId, allCards);
        return allCards.getCard(normalized).health || 30;
    }
    return 30;
};
exports.defaultStartingHp = defaultStartingHp;
const isBattlegrounds = (gameType) => {
    return ([
        public_api_1.GameType.GT_BATTLEGROUNDS,
        public_api_1.GameType.GT_BATTLEGROUNDS_FRIENDLY,
        public_api_1.GameType.GT_BATTLEGROUNDS_AI_VS_AI,
        public_api_1.GameType.GT_BATTLEGROUNDS_PLAYER_VS_AI,
        public_api_1.GameType.GT_BATTLEGROUNDS_DUO,
        public_api_1.GameType.GT_BATTLEGROUNDS_DUO_VS_AI,
        public_api_1.GameType.GT_BATTLEGROUNDS_DUO_FRIENDLY,
        public_api_1.GameType.GT_BATTLEGROUNDS_DUO_AI_VS_AI,
    ].includes(gameType) ||
        ['battlegrounds', 'battlegrounds-duo', 'battlegrounds-friendly'].includes(gameType));
};
exports.isBattlegrounds = isBattlegrounds;
const isBattlegroundsDuo = (gameType) => {
    return [
        public_api_1.GameType.GT_BATTLEGROUNDS_DUO,
        public_api_1.GameType.GT_BATTLEGROUNDS_DUO_VS_AI,
        public_api_1.GameType.GT_BATTLEGROUNDS_DUO_FRIENDLY,
        public_api_1.GameType.GT_BATTLEGROUNDS_DUO_AI_VS_AI,
    ].includes(gameType);
};
exports.isBattlegroundsDuo = isBattlegroundsDuo;
const normalizeHeroCardId = (heroCardId, allCards) => {
    if (!heroCardId) {
        return heroCardId;
    }
    const normalizedAfterSkin = normalizeHeroCardIdAfterSkin(heroCardId, allCards);
    switch (normalizedAfterSkin) {
        case 'TB_BaconShop_HERO_59t':
            return 'TB_BaconShop_HERO_59';
        case public_api_1.CardIds.QueenAzshara_NagaQueenAzsharaToken:
            return public_api_1.CardIds.QueenAzshara_BG22_HERO_007;
        default:
            return normalizedAfterSkin;
    }
};
exports.normalizeHeroCardId = normalizeHeroCardId;
const normalizeHeroCardIdAfterSkin = (heroCardId, allCards) => {
    const heroCard = allCards.getCard(heroCardId);
    if (!!(heroCard === null || heroCard === void 0 ? void 0 : heroCard.battlegroundsHeroParentDbfId)) {
        const parentCard = allCards.getCard(heroCard.battlegroundsHeroParentDbfId);
        if (!!parentCard) {
            return parentCard.id;
        }
    }
    const bgHeroSkinMatch = heroCardId.match(/(.*)_SKIN_.*/);
    if (bgHeroSkinMatch) {
        return bgHeroSkinMatch[1];
    }
    return heroCardId;
};
const normalizeMinionCardId = (cardId, allCards) => {
    const refCard = allCards.getCard(cardId);
    if (refCard === null || refCard === void 0 ? void 0 : refCard.battlegroundsNormalDbfId) {
        const normalCard = allCards.getCard(refCard.battlegroundsNormalDbfId);
        return normalCard === null || normalCard === void 0 ? void 0 : normalCard.id;
    }
    return cardId;
};
exports.normalizeMinionCardId = normalizeMinionCardId;
const getTribeName = (tribe, i18n) => {
    var _a;
    const tribeString = (_a = public_api_1.Race[tribe]) !== null && _a !== void 0 ? _a : public_api_1.GameTag[tribe];
    return i18n.translateString(`app.battlegrounds.tribes.${tribeString === null || tribeString === void 0 ? void 0 : tribeString.toLowerCase()}`);
};
exports.getTribeName = getTribeName;
const getTribeIcon = (tribe) => {
    const referenceCardId = exports.getReferenceTribeCardId(tribe);
    return `https://static.zerotoheroes.com/hearthstone/cardart/256x/${referenceCardId}.jpg`;
};
exports.getTribeIcon = getTribeIcon;
const getReferenceTribeCardId = (tribe) => {
    var _a;
    let referenceCardId;
    tribe = ((_a = tribe) === null || _a === void 0 ? void 0 : _a.padStart) ? tribe.toLowerCase() : tribe;
    switch (tribe) {
        case 'mech':
        case public_api_1.Race.MECH:
            referenceCardId = public_api_1.CardIds.DeflectOBot_BGS_071;
            break;
        case 'beast':
        case public_api_1.Race.BEAST:
            referenceCardId = public_api_1.CardIds.GoldrinnTheGreatWolf_BGS_018;
            break;
        case 'demon':
        case public_api_1.Race.DEMON:
            referenceCardId = public_api_1.CardIds.ImpulsiveTrickster_BG21_006;
            break;
        case 'dragon':
        case public_api_1.Race.DRAGON:
            referenceCardId = public_api_1.CardIds.PersistentPoet_BG29_813;
            break;
        case 'murloc':
        case public_api_1.Race.MURLOC:
            referenceCardId = public_api_1.CardIds.PrimalfinLookout_BGS_020;
            break;
        case 'pirate':
        case public_api_1.Race.PIRATE:
            referenceCardId = public_api_1.CardIds.SouthseaBusker_BG26_135;
            break;
        case 'elemental':
        case public_api_1.Race.ELEMENTAL:
            referenceCardId = public_api_1.CardIds.Sellemental_BGS_115;
            break;
        case 'naga':
        case public_api_1.Race.NAGA:
            referenceCardId = public_api_1.CardIds.ShellCollector_BG23_002;
            break;
        case 'quilboar':
        case public_api_1.Race.QUILBOAR:
            referenceCardId = public_api_1.CardIds.SunBaconRelaxer_BG20_301;
            break;
        case 'undead':
        case public_api_1.Race.UNDEAD:
            referenceCardId = public_api_1.CardIds.RisenRider_BG25_001;
            break;
        case 'all':
        case public_api_1.Race.ALL:
            referenceCardId = public_api_1.CardIds.AmalgamOfTheDeep_BG_TSC_069;
            break;
        case public_api_1.GameTag.PROTOSS:
            referenceCardId = public_api_1.CardIds.WarpGate_MothershipToken_BG31_HERO_802pt7;
            break;
        case public_api_1.GameTag.ZERG:
            referenceCardId = public_api_1.CardIds.KerriganQueenOfBlades_LarvaToken_BG31_HERO_811t;
            break;
        default:
            referenceCardId = public_api_1.CardIds.PatientScout_BG24_715;
            break;
    }
    return referenceCardId;
};
exports.getReferenceTribeCardId = getReferenceTribeCardId;
const getHeroPower = (heroCardId, allCards) => {
    const normalized = exports.normalizeHeroCardId(heroCardId, allCards);
    switch (normalized) {
        case 'TB_BaconShop_HERO_01':
            return 'TB_BaconShop_HP_001';
        case 'TB_BaconShop_HERO_02':
            return 'TB_BaconShop_HP_011';
        case 'TB_BaconShop_HERO_08':
            return 'TB_BaconShop_HP_069';
        case public_api_1.CardIds.RagnarosTheFirelord_TB_BaconShop_HERO_11:
            return public_api_1.CardIds.DieInsects_TB_BaconShop_HP_087;
        case 'TB_BaconShop_HERO_12':
            return 'TB_BaconShop_HP_041';
        case public_api_1.CardIds.QueenWagtoggle_TB_BaconShop_HERO_14:
            return public_api_1.CardIds.WaxWarband;
        case 'TB_BaconShop_HERO_15':
            return 'TB_BaconShop_HP_010';
        case 'TB_BaconShop_HERO_16':
            return 'TB_BaconShop_HP_044';
        case 'TB_BaconShop_HERO_17':
            return 'TB_BaconShop_HP_015';
        case 'TB_BaconShop_HERO_18':
            return 'TB_BaconShop_HP_072';
        case 'TB_BaconShop_HERO_20':
            return 'TB_BaconShop_HP_018';
        case 'TB_BaconShop_HERO_21':
            return 'TB_BaconShop_HP_020';
        case 'TB_BaconShop_HERO_22':
            return 'TB_BaconShop_HP_024';
        case public_api_1.CardIds.Shudderwock_TB_BaconShop_HERO_23:
            return public_api_1.CardIds.SnickerSnack;
        case 'TB_BaconShop_HERO_25':
            return 'TB_BaconShop_HP_049';
        case 'TB_BaconShop_HERO_27':
            return 'TB_BaconShop_HP_014';
        case 'TB_BaconShop_HERO_28':
            return 'TB_BaconShop_HP_028';
        case 'TB_BaconShop_HERO_30':
            return 'TB_BaconShop_HP_043';
        case 'TB_BaconShop_HERO_31':
            return 'TB_BaconShop_HP_009';
        case 'TB_BaconShop_HERO_33':
            return 'TB_BaconShop_HP_033';
        case 'TB_BaconShop_HERO_34':
            return 'TB_BaconShop_HP_035';
        case 'TB_BaconShop_HERO_35':
            return public_api_1.CardIds.PuzzleBox_PuzzleBoxToken_TB_BaconShop_HP_039t;
        case 'TB_BaconShop_HERO_36':
            return 'TB_BaconShop_HP_042';
        case 'TB_BaconShop_HERO_37':
            return 'TB_BaconShop_HP_036';
        case 'TB_BaconShop_HERO_38':
            return 'TB_BaconShop_HP_038';
        case 'TB_BaconShop_HERO_39':
            return 'TB_BaconShop_HP_040';
        case 'TB_BaconShop_HERO_40':
            return 'TB_BaconShop_HP_057';
        case 'TB_BaconShop_HERO_41':
            return 'TB_BaconShop_HP_046';
        case 'TB_BaconShop_HERO_42':
            return 'TB_BaconShop_HP_047';
        case 'TB_BaconShop_HERO_43':
            return 'TB_BaconShop_HP_048';
        case 'TB_BaconShop_HERO_45':
            return 'TB_BaconShop_HP_053';
        case 'TB_BaconShop_HERO_47':
            return 'TB_BaconShop_HP_051';
        case 'TB_BaconShop_HERO_49':
            return 'TB_BaconShop_HP_054';
        case 'TB_BaconShop_HERO_50':
            return 'TB_BaconShop_HP_077';
        case 'TB_BaconShop_HERO_52':
            return 'TB_BaconShop_HP_061';
        case 'TB_BaconShop_HERO_53':
            return 'TB_BaconShop_HP_062';
        case 'TB_BaconShop_HERO_55':
            return 'TB_BaconShop_HP_056';
        case 'TB_BaconShop_HERO_56':
            return 'TB_BaconShop_HP_064';
        case 'TB_BaconShop_HERO_57':
            return 'TB_BaconShop_HP_063';
        case 'TB_BaconShop_HERO_58':
            return 'TB_BaconShop_HP_052';
        case 'TB_BaconShop_HERO_59t':
            return 'TB_BaconShop_HP_065t2';
        case 'TB_BaconShop_HERO_59':
            return 'TB_BaconShop_HP_065';
        case 'TB_BaconShop_HERO_60':
            return 'TB_BaconShop_HP_066';
        case 'TB_BaconShop_HERO_61':
            return 'TB_BaconShop_HP_067';
        case 'TB_BaconShop_HERO_62':
            return 'TB_BaconShop_HP_068';
        case 'TB_BaconShop_HERO_64':
            return 'TB_BaconShop_HP_074';
        case public_api_1.CardIds.CaptainHooktusk_TB_BaconShop_HERO_67:
            return public_api_1.CardIds.TrashForTreasure;
        case 'TB_BaconShop_HERO_68':
            return 'TB_BaconShop_HP_076';
        case 'TB_BaconShop_HERO_70':
            return 'TB_BaconShop_HP_080';
        case 'TB_BaconShop_HERO_71':
            return 'TB_BaconShop_HP_084';
        case 'TB_BaconShop_HERO_72':
            return 'TB_BaconShop_HP_081';
        case 'TB_BaconShop_HERO_74':
            return 'TB_BaconShop_HP_082';
        case public_api_1.CardIds.Chenvaala_TB_BaconShop_HERO_78:
            return public_api_1.CardIds.Avalanche_TB_BaconShop_HP_088;
        case public_api_1.CardIds.Rakanishu_TB_BaconShop_HERO_75:
            return public_api_1.CardIds.TavernLighting;
        case public_api_1.CardIds.Alakir:
            return public_api_1.CardIds.SwattingInsects;
        case public_api_1.CardIds.ZephrysTheGreat_TB_BaconShop_HERO_91:
            return public_api_1.CardIds.ThreeWishes;
        case public_api_1.CardIds.SilasDarkmoon_TB_BaconShop_HERO_90:
            return public_api_1.CardIds.ComeOneComeAll;
        case public_api_1.CardIds.Cthun_TB_BaconShop_HERO_29:
            return public_api_1.CardIds.SaturdayCthuns;
        case public_api_1.CardIds.Nzoth:
            return public_api_1.CardIds.AvatarOfNzoth;
        case public_api_1.CardIds.Yshaarj:
            return public_api_1.CardIds.EmbraceYourRage;
        case public_api_1.CardIds.Tickatus_TB_BaconShop_HERO_94:
            return public_api_1.CardIds.PrizeWall;
        case public_api_1.CardIds.Greybough_TB_BaconShop_HERO_95:
            return public_api_1.CardIds.SproutItOut;
        case public_api_1.CardIds.OverlordSaurfang_BG20_HERO_102:
            return public_api_1.CardIds.OverlordSaurfang_ForTheHorde;
        case public_api_1.CardIds.DeathSpeakerBlackthorn_BG20_HERO_103:
            return public_api_1.CardIds.DeathSpeakerBlackthorn_Bloodbound;
        case public_api_1.CardIds.Voljin_BG20_HERO_201:
            return public_api_1.CardIds.Voljin_SpiritSwap_BG20_HERO_201p;
        case public_api_1.CardIds.Xyrella_BG20_HERO_101:
            return public_api_1.CardIds.Xyrella_SeeTheLight;
        case public_api_1.CardIds.MutanusTheDevourer_BG20_HERO_301:
            return public_api_1.CardIds.MutanusTheDevourer_Devour;
        case public_api_1.CardIds.GuffRunetotem_BG20_HERO_242:
            return public_api_1.CardIds.GuffRunetotem_NaturalBalance;
        case public_api_1.CardIds.KurtrusAshfallen_BG20_HERO_280:
            return public_api_1.CardIds.KurtrusAshfallen_GlaiveRicochet;
        case public_api_1.CardIds.Galewing:
            return public_api_1.CardIds.Galewing_DungarsGryphon;
        case public_api_1.CardIds.TradePrinceGallywix_TB_BaconShop_HERO_10:
            return public_api_1.CardIds.SmartSavings;
        case public_api_1.CardIds.MasterNguyen:
            return public_api_1.CardIds.MasterNguyen_PowerOfTheStorm;
        case public_api_1.CardIds.CarielRoame_BG21_HERO_000:
            return public_api_1.CardIds.CarielRoame_Conviction;
        case public_api_1.CardIds.Sneed_BG21_HERO_030:
            return public_api_1.CardIds.Sneed_SneedsReplicator;
        case public_api_1.CardIds.CookieTheCook_BG21_HERO_020:
            return public_api_1.CardIds.CookieTheCook_StirThePot;
        case public_api_1.CardIds.TamsinRoame_BG20_HERO_282:
            return public_api_1.CardIds.TamsinRoame_FragrantPhylactery;
        case public_api_1.CardIds.ScabbsCutterbutter_BG21_HERO_010:
            return public_api_1.CardIds.ScabbsCutterbutter_ISpy;
        case public_api_1.CardIds.Brukan_BG22_HERO_001:
            return public_api_1.CardIds.Brukan_EmbraceTheElements;
        case public_api_1.CardIds.Drekthar_BG22_HERO_002:
            return public_api_1.CardIds.Drekthar_LeadTheFrostwolves;
        case public_api_1.CardIds.VanndarStormpike_BG22_HERO_003:
            return public_api_1.CardIds.VanndarStormpike_LeadTheStormpikes;
        case public_api_1.CardIds.TavishStormpike_BG22_HERO_000:
            return public_api_1.CardIds.TavishStormpike_Deadeye;
        case public_api_1.CardIds.VardenDawngrasp_BG22_HERO_004:
            return public_api_1.CardIds.VardenDawngrasp_TwiceAsNice;
        case public_api_1.CardIds.Rokara_BG20_HERO_100:
            return public_api_1.CardIds.Rokara_GloryOfCombat;
        case public_api_1.CardIds.Onyxia_BG22_HERO_305:
            return public_api_1.CardIds.Onyxia_Broodmother;
        case public_api_1.CardIds.AmbassadorFaelin_BG22_HERO_201:
            return public_api_1.CardIds.AmbassadorFaelin_ExpeditionPlans;
        case public_api_1.CardIds.IniStormcoil_BG22_HERO_200:
            return public_api_1.CardIds.IniStormcoil_Mechgyver;
        case public_api_1.CardIds.QueenAzshara_BG22_HERO_007:
            return public_api_1.CardIds.QueenAzshara_AzsharasAmbition;
        case public_api_1.CardIds.QueenAzshara_NagaQueenAzsharaToken:
            return public_api_1.CardIds.QueenAzshara_NagaConquest;
        case public_api_1.CardIds.Ozumat_BG23_HERO_201:
            return public_api_1.CardIds.Ozumat_Tentacular;
        case public_api_1.CardIds.LadyVashj_BG23_HERO_304:
            return public_api_1.CardIds.LadyVashj_RelicsOfTheDeep;
        case public_api_1.CardIds.HeistbaronTogwaggle_BG23_HERO_305:
            return public_api_1.CardIds.HeistbaronTogwaggle_ThePerfectCrime;
        case public_api_1.CardIds.MurlocHolmes_BG23_HERO_303:
            return public_api_1.CardIds.MurlocHolmes_DetectiveForHire;
        case public_api_1.CardIds.SireDenathrius_BG24_HERO_100:
            return public_api_1.CardIds.SireDenathrius_Whodunitquestion;
        case public_api_1.CardIds.SylvanasWindrunner_BG23_HERO_306:
            return public_api_1.CardIds.SylvanasWindrunner_ReclaimedSouls;
        case public_api_1.CardIds.TheJailer_TB_BaconShop_HERO_702:
            return public_api_1.CardIds.RunicEmpowerment;
        case public_api_1.CardIds.EnhanceOMechano_BG24_HERO_204:
            return public_api_1.CardIds.EnhanceOMechano_Enhancification;
        case public_api_1.CardIds.ProfessorPutricide_BG25_HERO_100:
            return public_api_1.CardIds.ProfessorPutricide_BuildAnUndead;
        case public_api_1.CardIds.TeronGorefiend_BG25_HERO_103:
            return public_api_1.CardIds.TeronGorefiend_RapidReanimation;
        case public_api_1.CardIds.ETCBandManager_BG25_HERO_105:
            return public_api_1.CardIds.ETCBandManager_SignANewArtist;
        case public_api_1.CardIds.RockMasterVoone_BG26_HERO_104:
            return public_api_1.CardIds.RockMasterVoone_UpbeatHarmony;
        case public_api_1.CardIds.IngeTheIronHymn:
            return public_api_1.CardIds.IngeTheIronHymn_MajorHymn;
        case public_api_1.CardIds.CapnHoggarr_BG26_HERO_101:
            return public_api_1.CardIds.CapnHoggarr_ImTheCapnNow;
        case public_api_1.CardIds.ThorimStormlord_BG27_HERO_801:
            return public_api_1.CardIds.ThorimStormlord_ChooseYourChampion_BG27_HERO_801p2;
        case public_api_1.CardIds.SnakeEyes_BG28_HERO_400:
            return public_api_1.CardIds.SnakeEyes_LuckyRoll_BG28_HERO_400p;
        case public_api_1.CardIds.TaethelanBloodwatcher_BG28_HERO_800:
            return public_api_1.CardIds.TaethelanBloodwatcher_ReliquaryResearch_BG28_HERO_800p;
        case public_api_1.CardIds.DoctorHollidae_BG28_HERO_801:
            return public_api_1.CardIds.DoctorHollidae_BlessingOfTheNineFrogs_BG28_HERO_801p;
        case public_api_1.CardIds.Cho_BGDUO_HERO_222:
            return public_api_1.CardIds.Cho_DoubleTrouble_BGDUO_HERO_222p;
        case public_api_1.CardIds.Gall_BGDUO_HERO_223:
            return public_api_1.CardIds.Gall_DoubleTrouble_BGDUO_HERO_223p;
        case public_api_1.CardIds.TheNamelessOne_BGDUO_HERO_100:
            return public_api_1.CardIds.TheNamelessOne_X_BGDUO_HERO_100p;
        case public_api_1.CardIds.FlobbidinousFloop_BGDUO_HERO_101:
            return public_api_1.CardIds.FlobbidinousFloop_GloriousGloop_BGDUO_HERO_101p;
        case public_api_1.CardIds.MadamGoya_BGDUO_HERO_104:
            return public_api_1.CardIds.MadamGoya_EfficientExchange_BGDUO_HERO_104p;
        case public_api_1.CardIds.MarinTheManager_BG30_HERO_304:
            return public_api_1.CardIds.MarinTheManager_FantasticTreasure_BG30_HERO_304p;
        case public_api_1.CardIds.FarseerNobundo_BG31_HERO_003:
            return public_api_1.CardIds.FarseerNobundo_TheGalaxysLens_BG31_HERO_003p;
        case public_api_1.CardIds.ExarchOthaar_BG31_HERO_006:
            return public_api_1.CardIds.ExarchOthaar_ArcaneKnowledge_BG31_HERO_006p;
        case public_api_1.CardIds.ZerekMasterCloner_BG31_HERO_005:
            return public_api_1.CardIds.ZerekMasterCloner_CloningGallery_BG31_HERO_005p;
        case public_api_1.CardIds.JimRaynor_BG31_HERO_801:
            return public_api_1.CardIds.JimRaynor_LiftOff_BG31_HERO_801p;
        case public_api_1.CardIds.Artanis_BG31_HERO_802:
            return public_api_1.CardIds.Artanis_WarpGate_BG31_HERO_802p;
        case public_api_1.CardIds.KerriganQueenOfBlades_BG31_HERO_811:
            return public_api_1.CardIds.KerriganQueenOfBlades_SpawningPool_BG31_HERO_811p;
        case public_api_1.CardIds.Buttons_BG32_HERO_002:
            return public_api_1.CardIds.Buttons_GrowingCollection_BG32_HERO_002p;
        case public_api_1.CardIds.ForestLordCenarius_BG32_HERO_001:
            return public_api_1.CardIds.ForestLordCenarius_WisdomOfAncients_BG32_HERO_001p;
        case public_api_1.CardIds.LohTheLivingLegend_BG33_HERO_001:
            return public_api_1.CardIds.HeroicInspiration_BG33_HERO_001p_ALT;
        case public_api_1.CardIds.MurozondUnbounded_BG34_HERO_000:
            return public_api_1.CardIds.MurozondUnbounded_AlternateTimeline_BG34_HERO_000p;
        case public_api_1.CardIds.TimeTwisterChromie_BG34_HERO_001:
            return public_api_1.CardIds.TimeTwisterChromie_ManaPerMinute_BG34_HERO_001p;
        case '':
            return null;
    }
};
exports.getHeroPower = getHeroPower;
const getBuddy = (heroCardId, allCards) => {
    switch (exports.normalizeHeroCardId(heroCardId, allCards)) {
        case public_api_1.CardIds.AFKay_TB_BaconShop_HERO_16:
            return public_api_1.CardIds.SnackVendor_TB_BaconShop_HERO_16_Buddy;
        case public_api_1.CardIds.Alakir:
            return public_api_1.CardIds.SpiritOfAir_TB_BaconShop_HERO_76_Buddy;
        case public_api_1.CardIds.Alexstrasza_TB_BaconShop_HERO_56:
            return public_api_1.CardIds.Vaelastrasz_TB_BaconShop_HERO_56_Buddy;
        case public_api_1.CardIds.ArannaStarseeker_ArannaUnleashedToken:
        case public_api_1.CardIds.ArannaStarseeker_TB_BaconShop_HERO_59:
            return public_api_1.CardIds.SklibbDemonHunter_TB_BaconShop_HERO_59_Buddy;
        case public_api_1.CardIds.ArchVillainRafaam_TB_BaconShop_HERO_45:
            return public_api_1.CardIds.LoyalHenchman_TB_BaconShop_HERO_45_Buddy;
        case public_api_1.CardIds.Brukan_BG22_HERO_001:
            return public_api_1.CardIds.SpiritRaptor_BG22_HERO_001_Buddy;
        case public_api_1.CardIds.CaptainEudora_TB_BaconShop_HERO_64:
            return public_api_1.CardIds.DagwikStickytoe_TB_BaconShop_HERO_64_Buddy;
        case public_api_1.CardIds.CaptainHooktusk_TB_BaconShop_HERO_67:
            return public_api_1.CardIds.RagingContender_TB_BaconShop_HERO_67_Buddy;
        case public_api_1.CardIds.CarielRoame_BG21_HERO_000:
            return public_api_1.CardIds.CaptainFairmount_BG21_HERO_000_Buddy;
        case public_api_1.CardIds.Chenvaala_TB_BaconShop_HERO_78:
            return public_api_1.CardIds.SnowElemental_TB_BaconShop_HERO_78_Buddy;
        case public_api_1.CardIds.CookieTheCook_BG21_HERO_020:
            return public_api_1.CardIds.SousChef_BG21_HERO_020_Buddy;
        case public_api_1.CardIds.Cthun_TB_BaconShop_HERO_29:
            return public_api_1.CardIds.TentacleOfCthun_TB_BaconShop_HERO_29_Buddy;
        case public_api_1.CardIds.DancinDeryl:
            return public_api_1.CardIds.AsherTheHaberdasher_TB_BaconShop_HERO_36_Buddy;
        case public_api_1.CardIds.DeathSpeakerBlackthorn_BG20_HERO_103:
            return public_api_1.CardIds.DeathsHeadSage_BG20_HERO_103_Buddy;
        case public_api_1.CardIds.Deathwing_TB_BaconShop_HERO_52:
            return public_api_1.CardIds.LadySinestra_TB_BaconShop_HERO_52_Buddy;
        case public_api_1.CardIds.DinotamerBrann_TB_BaconShop_HERO_43:
            return public_api_1.CardIds.BrannsEpicEgg_TB_BaconShop_HERO_43_Buddy;
        case public_api_1.CardIds.Drekthar_BG22_HERO_002:
            return public_api_1.CardIds.FrostwolfLieutenant_BG22_HERO_002_Buddy;
        case public_api_1.CardIds.EdwinVancleef_TB_BaconShop_HERO_01:
            return public_api_1.CardIds.Si7Scout_TB_BaconShop_HERO_01_Buddy;
        case public_api_1.CardIds.EliseStarseeker_TB_BaconShop_HERO_42:
            return public_api_1.CardIds.JrNavigator_TB_BaconShop_HERO_42_Buddy;
        case public_api_1.CardIds.ForestWardenOmu_TB_BaconShop_HERO_74:
            return public_api_1.CardIds.EvergreenBotani_TB_BaconShop_HERO_74_Buddy;
        case public_api_1.CardIds.FungalmancerFlurgl:
            return public_api_1.CardIds.SparkfinSoothsayer_TB_BaconShop_HERO_55_Buddy;
        case public_api_1.CardIds.Galakrond:
            return public_api_1.CardIds.ApostleOfGalakrond_TB_BaconShop_HERO_02_Buddy;
        case public_api_1.CardIds.Galewing:
            return public_api_1.CardIds.FlightTrainer_BG20_HERO_283_Buddy;
        case public_api_1.CardIds.GeorgeTheFallen_TB_BaconShop_HERO_15:
            return public_api_1.CardIds.KarlTheLost_TB_BaconShop_HERO_15_Buddy;
        case public_api_1.CardIds.Greybough_TB_BaconShop_HERO_95:
            return public_api_1.CardIds.WanderingTreant_TB_BaconShop_HERO_95_Buddy;
        case public_api_1.CardIds.GuffRunetotem_BG20_HERO_242:
            return public_api_1.CardIds.BabyKodo_BG20_HERO_242_Buddy;
        case public_api_1.CardIds.IllidanStormrage_TB_BaconShop_HERO_08:
            return public_api_1.CardIds.EclipsionIllidari_TB_BaconShop_HERO_08_Buddy;
        case public_api_1.CardIds.InfiniteToki:
            return public_api_1.CardIds.ClockworkAssistant_TB_BaconShop_HERO_28_Buddy;
        case public_api_1.CardIds.JandiceBarov_TB_BaconShop_HERO_71:
            return public_api_1.CardIds.JandicesApprentice_TB_BaconShop_HERO_71_Buddy;
        case public_api_1.CardIds.KaelthasSunstrider_TB_BaconShop_HERO_60:
            return public_api_1.CardIds.CrimsonHandCenturion_TB_BaconShop_HERO_60_Buddy;
        case public_api_1.CardIds.KingMukla_TB_BaconShop_HERO_38:
            return public_api_1.CardIds.CrazyMonkey_TB_BaconShop_HERO_38_Buddy;
        case public_api_1.CardIds.KurtrusAshfallen_BG20_HERO_280:
            return public_api_1.CardIds.LivingNightmare_BG20_HERO_280_Buddy;
        case public_api_1.CardIds.LichBazhial:
            return public_api_1.CardIds.UnearthedUnderling_TB_BaconShop_HERO_25_Buddy;
        case public_api_1.CardIds.LordBarov_TB_BaconShop_HERO_72:
            return public_api_1.CardIds.BarovsApprentice_TB_BaconShop_HERO_72_Buddy;
        case public_api_1.CardIds.LordJaraxxus_TB_BaconShop_HERO_37:
            return public_api_1.CardIds.Kilrek_TB_BaconShop_HERO_37_Buddy;
        case public_api_1.CardIds.MaievShadowsong_TB_BaconShop_HERO_62:
            return public_api_1.CardIds.ShadowWarden_TB_BaconShop_HERO_62_Buddy;
        case public_api_1.CardIds.Malygos:
            return public_api_1.CardIds.NexusLord_TB_BaconShop_HERO_58_Buddy;
        case public_api_1.CardIds.MasterNguyen:
            return public_api_1.CardIds.LeiFlamepaw_BG20_HERO_202_Buddy;
        case public_api_1.CardIds.MillhouseManastorm_TB_BaconShop_HERO_49:
            return public_api_1.CardIds.MagnusManastorm_TB_BaconShop_HERO_49_Buddy;
        case public_api_1.CardIds.MillificentManastorm:
            return public_api_1.CardIds.ElementiumSquirrelBomb_TB_BaconShop_HERO_17_Buddy;
        case public_api_1.CardIds.MrBigglesworth_TB_BaconShop_HERO_70:
            return public_api_1.CardIds.LilKT_TB_BaconShop_HERO_70_Buddy;
        case public_api_1.CardIds.MutanusTheDevourer_BG20_HERO_301:
            return public_api_1.CardIds.NightmareEctoplasm_BG20_HERO_301_Buddy;
        case public_api_1.CardIds.Nozdormu_TB_BaconShop_HERO_57:
            return public_api_1.CardIds.Chromie_TB_BaconShop_HERO_57_Buddy;
        case public_api_1.CardIds.Nzoth:
            return public_api_1.CardIds.BabyNzoth_TB_BaconShop_HERO_93_Buddy;
        case public_api_1.CardIds.OverlordSaurfang_BG20_HERO_102:
            return public_api_1.CardIds.DranoshSaurfang_BG20_HERO_102_Buddy;
        case public_api_1.CardIds.PatchesThePirate_TB_BaconShop_HERO_18:
            return public_api_1.CardIds.TuskarrRaider_TB_BaconShop_HERO_18_Buddy;
        case public_api_1.CardIds.Patchwerk_TB_BaconShop_HERO_34:
            return public_api_1.CardIds.Weebomination_TB_BaconShop_HERO_34_Buddy;
        case public_api_1.CardIds.Pyramad:
            return public_api_1.CardIds.TitanicGuardian_TB_BaconShop_HERO_39_Buddy;
        case public_api_1.CardIds.QueenWagtoggle_TB_BaconShop_HERO_14:
            return public_api_1.CardIds.ElderTaggawag_TB_BaconShop_HERO_14_Buddy;
        case public_api_1.CardIds.RagnarosTheFirelord_TB_BaconShop_HERO_11:
            return public_api_1.CardIds.Lucifron_TB_BaconShop_HERO_11_Buddy;
        case public_api_1.CardIds.Rakanishu_TB_BaconShop_HERO_75:
            return public_api_1.CardIds.LanternTender_TB_BaconShop_HERO_75_Buddy;
        case public_api_1.CardIds.RenoJackson_TB_BaconShop_HERO_41:
            return public_api_1.CardIds.SrTombDiver_TB_BaconShop_HERO_41_Buddy;
        case public_api_1.CardIds.ScabbsCutterbutter_BG21_HERO_010:
            return public_api_1.CardIds.WardenThelwater_BG21_HERO_010_Buddy;
        case public_api_1.CardIds.Shudderwock_TB_BaconShop_HERO_23:
            return public_api_1.CardIds.Muckslinger_TB_BaconShop_HERO_23_Buddy;
        case public_api_1.CardIds.SilasDarkmoon_TB_BaconShop_HERO_90:
            return public_api_1.CardIds.Burth_TB_BaconShop_HERO_90_Buddy;
        case public_api_1.CardIds.Sindragosa_TB_BaconShop_HERO_27:
            return public_api_1.CardIds.ThawedChampion_TB_BaconShop_HERO_27_Buddy;
        case public_api_1.CardIds.SirFinleyMrrgglton_TB_BaconShop_HERO_40:
            return public_api_1.CardIds.MaxwellMightySteed_TB_BaconShop_HERO_40_Buddy;
        case public_api_1.CardIds.SkycapnKragg_TB_BaconShop_HERO_68:
            return public_api_1.CardIds.Sharkbait_TB_BaconShop_HERO_68_Buddy;
        case public_api_1.CardIds.Sneed_BG21_HERO_030:
            return public_api_1.CardIds.PilotedWhirlOTron_BG21_HERO_030_Buddy;
        case public_api_1.CardIds.TamsinRoame_BG20_HERO_282:
            return public_api_1.CardIds.Monstrosity_BG20_HERO_282_Buddy;
        case public_api_1.CardIds.TavishStormpike_BG22_HERO_000:
            return public_api_1.CardIds.Crabby_BG22_HERO_000_Buddy;
        case public_api_1.CardIds.TessGreymane_TB_BaconShop_HERO_50:
            return public_api_1.CardIds.HunterOfOld_TB_BaconShop_HERO_50_Buddy;
        case public_api_1.CardIds.TheCurator_TB_BaconShop_HERO_33:
            return public_api_1.CardIds.Mishmash_TB_BaconShop_HERO_33_Buddy;
        case public_api_1.CardIds.TheGreatAkazamzarak:
            return public_api_1.CardIds.StreetMagician_TB_BaconShop_HERO_21_Buddy;
        case public_api_1.CardIds.TheLichKing_TB_BaconShop_HERO_22:
            return public_api_1.CardIds.Arfus_TB_BaconShop_HERO_22_Buddy;
        case public_api_1.CardIds.TheRatKing_TB_BaconShop_HERO_12:
            return public_api_1.CardIds.PigeonLord_TB_BaconShop_HERO_12_Buddy;
        case public_api_1.CardIds.Tickatus_TB_BaconShop_HERO_94:
            return public_api_1.CardIds.TicketCollector_TB_BaconShop_HERO_94_Buddy;
        case public_api_1.CardIds.TradePrinceGallywix_TB_BaconShop_HERO_10:
            return public_api_1.CardIds.BilgewaterMogul_TB_BaconShop_HERO_10_Buddy;
        case public_api_1.CardIds.VanndarStormpike_BG22_HERO_003:
            return public_api_1.CardIds.StormpikeLieutenant_BG22_HERO_003_Buddy;
        case public_api_1.CardIds.Voljin_BG20_HERO_201:
            return public_api_1.CardIds.MasterGadrin_BG20_HERO_201_Buddy;
        case public_api_1.CardIds.Xyrella_BG20_HERO_101:
            return public_api_1.CardIds.BabyElekk_BG20_HERO_101_Buddy;
        case public_api_1.CardIds.YoggSaronHopesEnd_TB_BaconShop_HERO_35:
            return public_api_1.CardIds.AcolyteOfYoggSaron_TB_BaconShop_HERO_35_Buddy;
        case public_api_1.CardIds.Ysera_TB_BaconShop_HERO_53:
            return public_api_1.CardIds.ValithriaDreamwalker_TB_BaconShop_HERO_53_Buddy;
        case public_api_1.CardIds.Yshaarj:
            return public_api_1.CardIds.BabyYshaarj_TB_BaconShop_HERO_92_Buddy;
        case public_api_1.CardIds.ZephrysTheGreat_TB_BaconShop_HERO_91:
            return public_api_1.CardIds.Phyresz_TB_BaconShop_HERO_91_Buddy;
        case public_api_1.CardIds.VardenDawngrasp_BG22_HERO_004:
            return public_api_1.CardIds.VardensAquarrior_BG22_HERO_004_Buddy;
        case public_api_1.CardIds.Rokara_BG20_HERO_100:
            return public_api_1.CardIds.IcesnarlTheMighty_BG20_HERO_100_Buddy;
        case public_api_1.CardIds.Onyxia_BG22_HERO_305:
            return public_api_1.CardIds.ManyWhelps_BG22_HERO_305_Buddy;
        case public_api_1.CardIds.AmbassadorFaelin_BG22_HERO_201:
            return public_api_1.CardIds.SubmersibleChef_BG22_HERO_201_Buddy;
        case public_api_1.CardIds.IniStormcoil_BG22_HERO_200:
            return public_api_1.CardIds.SubScrubber_BG22_HERO_200_Buddy;
        case public_api_1.CardIds.QueenAzshara_BG22_HERO_007:
            return public_api_1.CardIds.ImperialDefender_BG22_HERO_007_Buddy;
        case public_api_1.CardIds.Ozumat_BG23_HERO_201:
            return public_api_1.CardIds.Tamuzo_BG23_HERO_201_Buddy;
        case public_api_1.CardIds.LadyVashj_BG23_HERO_304:
            return public_api_1.CardIds.CoilfangElite_BG23_HERO_304_Buddy;
        case public_api_1.CardIds.HeistbaronTogwaggle_BG23_HERO_305:
            return public_api_1.CardIds.WaxadredTheDrippy_BG23_HERO_305_Buddy;
        case public_api_1.CardIds.SireDenathrius_BG24_HERO_100:
            return public_api_1.CardIds.ShadyAristocrat_BG24_HERO_100_Buddy;
        case public_api_1.CardIds.SylvanasWindrunner_BG23_HERO_306:
            return public_api_1.CardIds.NathanosBlightcaller_BG23_HERO_306_Buddy;
        case public_api_1.CardIds.TheJailer_TB_BaconShop_HERO_702:
            return public_api_1.CardIds.MawswornSoulkeeper_TB_BaconShop_HERO_702_Buddy;
        case public_api_1.CardIds.EnhanceOMechano_BG24_HERO_204:
            return public_api_1.CardIds.EnhanceOMedico_BG24_HERO_204_Buddy;
        case public_api_1.CardIds.ProfessorPutricide_BG25_HERO_100:
            return public_api_1.CardIds.Festergut_BG25_HERO_100_Buddy;
        case public_api_1.CardIds.TeronGorefiend_BG25_HERO_103:
            return public_api_1.CardIds.ShadowyConstruct_BG25_HERO_103_Buddy;
        case public_api_1.CardIds.MurlocHolmes_BG23_HERO_303:
            return public_api_1.CardIds.Watfin_BG23_HERO_303_Buddy;
        case public_api_1.CardIds.ETCBandManager_BG25_HERO_105:
            return public_api_1.CardIds.TalentScout_BG25_HERO_105_Buddy;
        case public_api_1.CardIds.CapnHoggarr_BG26_HERO_101:
            return public_api_1.CardIds.ShiningSailor_BG26_HERO_101_Buddy;
        case public_api_1.CardIds.IngeTheIronHymn:
            return public_api_1.CardIds.SolemnSerenader_BG26_HERO_102_Buddy;
        case public_api_1.CardIds.RockMasterVoone_BG26_HERO_104:
            return public_api_1.CardIds.AkaliRockRhino_BG26_HERO_104_Buddy;
        case public_api_1.CardIds.ThorimStormlord_BG27_HERO_801:
            return public_api_1.CardIds.VeranusStormlordsMount_BG27_HERO_801_Buddy;
        case public_api_1.CardIds.SnakeEyes_BG28_HERO_400:
            return public_api_1.CardIds.BoxCars_BG28_HERO_400_Buddy;
        case public_api_1.CardIds.DoctorHollidae_BG28_HERO_801:
            return public_api_1.CardIds.TheNineFrogs_BG28_HERO_801_Buddy;
        case public_api_1.CardIds.TaethelanBloodwatcher_BG28_HERO_800:
            return public_api_1.CardIds.ReliquaryAttendant_BG28_HERO_800_Buddy;
        case public_api_1.CardIds.TheNamelessOne_BGDUO_HERO_100:
            return public_api_1.CardIds.FacelessOne_BGDUO_HERO_100_Buddy;
        case public_api_1.CardIds.Cho_BGDUO_HERO_222:
            return public_api_1.CardIds.HalfusTheMighty_BGDUO_HERO_222_Buddy;
        case public_api_1.CardIds.Gall_BGDUO_HERO_223:
            return public_api_1.CardIds.HalfusTheWise_BGDUO_HERO_223_Buddy;
        case public_api_1.CardIds.MadamGoya_BGDUO_HERO_104:
            return public_api_1.CardIds.MisterChu_BGDUO_HERO_104_Buddy;
        case public_api_1.CardIds.FlobbidinousFloop_BGDUO_HERO_101:
            return public_api_1.CardIds.GloriousGloopling_BGDUO_HERO_101_Buddy;
        case public_api_1.CardIds.KerriganQueenOfBlades_BG31_HERO_811:
            return public_api_1.CardIds.BrokenHorn_BG31_HERO_811_Buddy;
        case public_api_1.CardIds.MarinTheManager_BG30_HERO_304:
            return public_api_1.CardIds.FantasticBellhop_BG30_HERO_304_Buddy;
        case public_api_1.CardIds.ForestLordCenarius_BG32_HERO_001:
            return public_api_1.CardIds.Malorne_BG32_HERO_001_Buddy;
        case public_api_1.CardIds.ExarchOthaar_BG31_HERO_006:
            return public_api_1.CardIds.TheCelestialArchive_BG31_HERO_006_Buddy;
        case public_api_1.CardIds.Buttons_BG32_HERO_002:
            return public_api_1.CardIds.Zippers_BG32_HERO_002_Buddy;
        case public_api_1.CardIds.ZerekMasterCloner_BG31_HERO_005:
            return public_api_1.CardIds.MiniZerek_BG31_HERO_005_Buddy;
        case public_api_1.CardIds.JimRaynor_BG31_HERO_801:
            return public_api_1.CardIds.TychusFindlay_BG31_HERO_801_Buddy;
        case public_api_1.CardIds.Artanis_BG31_HERO_802:
            return public_api_1.CardIds.Probius_BG31_HERO_802_Buddy;
        case public_api_1.CardIds.LohTheLivingLegend_BG33_HERO_001:
            return public_api_1.CardIds.StoneshellGuardian_BG33_HERO_000_Buddy;
        default:
            if (!!heroCardId) {
                console.debug('missing buddy section for ', heroCardId);
            }
            return null;
    }
};
exports.getBuddy = getBuddy;
const isBaconGhost = (cardId) => {
    return (cardId === public_api_1.CardIds.Kelthuzad_TB_BaconShop_HERO_KelThuzad ||
        cardId === public_api_1.CardIds.LadyDeathwhisper_TB_BaconShop_HERO_Deathwhisper);
};
exports.isBaconGhost = isBaconGhost;
const getEffectiveTribes = (card, groupMinionsIntoTheirTribeGroup) => {
    const tribes = groupMinionsIntoTheirTribeGroup
        ? exports.getTribesForInclusion(card, true)
        : exports.getEffectiveTribesEnum(card);
    return tribes.map((tribe) => public_api_1.Race[tribe]);
};
exports.getEffectiveTribes = getEffectiveTribes;
const getTribesForInclusion = (card, includeOwnTribe) => {
    var _a, _b;
    if (!card) {
        return [];
    }
    const nativeRaces = (_b = (_a = card.races) === null || _a === void 0 ? void 0 : _a.map((r) => public_api_1.Race[r])) !== null && _b !== void 0 ? _b : [];
    const cardRaces = includeOwnTribe ? nativeRaces : [];
    switch (card.id) {
        case public_api_1.CardIds.BirdBuddy_BG21_002:
        case public_api_1.CardIds.BirdBuddy_BG21_002_G:
        case public_api_1.CardIds.PackLeader_BGS_017:
        case public_api_1.CardIds.PackLeader_TB_BaconUps_086:
        case public_api_1.CardIds.VirmenSensei_CFM_816:
        case public_api_1.CardIds.HoundmasterLegacy:
        case public_api_1.CardIds.HoundmasterVanilla:
        case public_api_1.CardIds.Houndmaster_TB_BaconUps_068:
        case public_api_1.CardIds.Houndmaster_BG_DS1_070:
            return [public_api_1.Race.BEAST, ...cardRaces];
        case public_api_1.CardIds.ImpatientDoomsayer_BG21_007:
        case public_api_1.CardIds.ImpatientDoomsayer_BG21_007_G:
        case public_api_1.CardIds.SoulJuggler_BGS_002:
        case public_api_1.CardIds.SoulJuggler_TB_BaconUps_075:
        case public_api_1.CardIds.WrathWeaver_BGS_004:
        case public_api_1.CardIds.WrathWeaver_TB_BaconUps_079:
        case public_api_1.CardIds.CultistSthara_BG27_081:
        case public_api_1.CardIds.CultistSthara_BG27_081_G:
            return [public_api_1.Race.DEMON, ...cardRaces];
        case public_api_1.CardIds.SeafoodSlinger_BG21_011:
        case public_api_1.CardIds.SeafoodSlinger_BG21_011_G:
            return [public_api_1.Race.MURLOC, ...cardRaces];
        case public_api_1.CardIds.NadinaTheRed_BGS_040:
        case public_api_1.CardIds.NadinaTheRed_TB_BaconUps_154:
        case public_api_1.CardIds.WhelpSmuggler_BG21_013:
        case public_api_1.CardIds.WhelpSmuggler_BG21_013_G:
            return [public_api_1.Race.DRAGON, ...cardRaces];
        case public_api_1.CardIds.MajordomoExecutus_BGS_105:
        case public_api_1.CardIds.MajordomoExecutus_TB_BaconUps_207:
        case public_api_1.CardIds.MasterOfRealities_BG21_036:
        case public_api_1.CardIds.MasterOfRealities_BG21_036_G:
        case public_api_1.CardIds.NomiKitchenNightmare_BGS_104:
        case public_api_1.CardIds.NomiKitchenNightmare_TB_BaconUps_201:
            return [public_api_1.Race.ELEMENTAL, ...cardRaces];
        case public_api_1.CardIds.KangorsApprentice_BGS_012:
        case public_api_1.CardIds.KangorsApprentice_TB_BaconUps_087:
            return [public_api_1.Race.MECH, ...cardRaces];
        case public_api_1.CardIds.DefiantShipwright_BG21_018:
        case public_api_1.CardIds.DefiantShipwright_BG21_018_G:
        case public_api_1.CardIds.CoastGuard_BG31_827:
        case public_api_1.CardIds.CoastGuard_BG31_827_G:
            return [public_api_1.Race.PIRATE, ...cardRaces];
        case public_api_1.CardIds.AgamagganTheGreatBoar_BG20_205:
        case public_api_1.CardIds.AgamagganTheGreatBoar_BG20_205_G:
        case public_api_1.CardIds.ProphetOfTheBoar_BG20_203:
        case public_api_1.CardIds.ProphetOfTheBoar_BG20_203_G:
            return [public_api_1.Race.QUILBOAR, ...cardRaces];
        case public_api_1.CardIds.OrgozoaTheTender_BG23_015:
        case public_api_1.CardIds.OrgozoaTheTender_BG23_015_G:
            return [public_api_1.Race.NAGA, ...cardRaces];
        case public_api_1.CardIds.DisguisedGraverobber_BG28_303:
        case public_api_1.CardIds.DisguisedGraverobber_BG28_303_G:
            return [public_api_1.Race.UNDEAD, ...cardRaces];
        default:
            return exports.getEffectiveTribesEnum(card);
    }
};
exports.getTribesForInclusion = getTribesForInclusion;
exports.getEffectiveTribesEnum = hs_utils_1.getEffectiveTribesEnumBase;
//# sourceMappingURL=bgs-utils.js.map