pvp: 更改pvpdefense结构

This commit is contained in:
luying
2021-10-29 16:36:23 +08:00
parent 4a5e23969b
commit e39b120af4
31 changed files with 1542 additions and 1137 deletions
+4 -1
View File
@@ -1,5 +1,5 @@
// 关卡表
import {decodeArrayListStr, readWarJsonFileAndParse} from '../util'
import {decodeArrayListStr, parseNumberList, readWarJsonFileAndParse} from '../util'
export interface DicWarJson {
@@ -47,6 +47,8 @@ export interface DicWarJson {
readonly callSkillData: string;
// 敌军数量
readonly enemyCount: number;
// pvp中随机敌军
readonly randomEnemy: number[];
}
export const dicWarJson = new Map<number, Array<DicWarJson>>();
@@ -63,6 +65,7 @@ export function loadWarJson() {
if(o.relation == 2) enemyCount++;
});
arr.forEach(o => {
o.randomEnemy = parseNumberList(o.randomEnemy);
o.enemyCount = enemyCount;
warjson.push(o);
});