
export default class HeroSkinShared {


    /**
     * 计算皮肤buff
     * @param skid
     * @param lv
     * @returns {[string]: number}
     * */
    static calcBuff(skid: string, lv: number): k_v<number> {
        let buff = {};
        let skin = G.gc.heroSkin[skid];
        for (let i = 1; i <= lv; i++) {
            for (let k in (G.gc.heroSkinLv[skin.colour][i]?.buff || {})) {
                buff[k] = (buff[k] || 0) + G.gc.heroSkinLv[skin.colour][i].buff[k];
            }
        }
        return buff;
    }
}