✨ feat(稷下学宫): ff931afe4到7421822f6

This commit is contained in:
luying
2023-08-30 11:02:52 +08:00
parent 59a334d673
commit 05cbe318e9
102 changed files with 147876 additions and 715 deletions
@@ -0,0 +1,30 @@
/**
* 试炼难度配置表
*/
import { readFileAndParse } from '../util'
import { FILENAME } from '../../consts'
export interface DicRougeLayerNodePlan {
readonly id: number;
readonly nodePlanId: number; // 随机方案,dicRougeLayer的nodePlan引用
readonly nodeId: number; // 节点的类型,引用的是 dicRougeNode 表的nodeId
readonly weight: number;
}
// export const dicRougeLayerNodePlan = new Map<string, DicRougeLayerNodePlan>();
export const dicRougeLayerNodePlan = new Map<number, DicRougeLayerNodePlan[]>();
export function loadRougeLayerNodePlan() {
dicRougeLayerNodePlan.clear();
let arr = readFileAndParse(FILENAME.DIC_ROUGE_LAYER_NODE_PLAN);
arr.forEach(o => {
if (!dicRougeLayerNodePlan.get(o.nodePlanId)) dicRougeLayerNodePlan.set(o.nodePlanId, []);
dicRougeLayerNodePlan.get(o.nodePlanId).push(o);
});
arr = undefined;
}