关卡:主公经验和等级挂钩
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
// 任务奖励主公经验
|
||||
import { readFileAndParse, } from '../util'
|
||||
import { FILENAME, KING_EXP_RATIO_TYPE, } from '../../consts'
|
||||
|
||||
export interface DicKingExpRatio {
|
||||
// 主公等级
|
||||
readonly lv: number;
|
||||
// 主公经验
|
||||
readonly exp: number;
|
||||
// 关卡获得的武将经验
|
||||
readonly expGk: number;
|
||||
}
|
||||
|
||||
export const dicKingExpRatio = new Map<number, Map<KING_EXP_RATIO_TYPE, number>>();
|
||||
export function loadKingExpRatio() {
|
||||
|
||||
let arr1 = readFileAndParse(FILENAME.DIC_EXP_RATIO);
|
||||
arr1.forEach(o => {
|
||||
let map = new Map<KING_EXP_RATIO_TYPE, number>();
|
||||
map.set(KING_EXP_RATIO_TYPE.TASK, o.exp);
|
||||
map.set(KING_EXP_RATIO_TYPE.BATTLE, o.expGk);
|
||||
dicKingExpRatio.set(o.lv, map);
|
||||
});
|
||||
arr1 = undefined;
|
||||
}
|
||||
Reference in New Issue
Block a user