// 藏宝图合成表
import { readFileAndParse } from '../util'
import { FILENAME } from '../../consts'

export interface DicBlueprtCompose {

    // 品质
    readonly quality: number;
    // 消耗的寻宝币数量
    readonly coinNum: number;
    // 消耗的藏宝图的数量
    readonly blueprtNum: number;
    // 目标品质
    readonly targetQuality: number;

}

export const dicBlueprtCompose = new Map<number, DicBlueprtCompose>();
export function loadBlueprtCompose() {
    let arr = readFileAndParse(FILENAME.DIC_BLUEPRT_COMPOSE);

    arr.forEach(o => {
        dicBlueprtCompose.set(o.quality, o);
    });
    arr = undefined;
}
