军团:修改个人功勋→个人活跃
This commit is contained in:
@@ -19,10 +19,10 @@ export interface DicGuildActiveWeekReward {
|
||||
const str = readJsonFile(FILENAME.DIC_ACTIVE_DAY_REWARD);
|
||||
let arr = JSON.parse(str);
|
||||
|
||||
export const dicGuildActiveWeekReward = new Map<number, DicGuildActiveWeekReward>();
|
||||
export const dicGuildActiveWeekReward = new Array<DicGuildActiveWeekReward>();
|
||||
|
||||
arr.forEach(o => {
|
||||
o.reward = parseGoodStr(o.Reward)
|
||||
dicGuildActiveWeekReward.set(o.id, o);
|
||||
dicGuildActiveWeekReward.push(o);
|
||||
});
|
||||
arr = undefined;
|
||||
@@ -16,7 +16,7 @@ export interface DicGuildPosition {
|
||||
readonly activeRatio: number;
|
||||
}
|
||||
|
||||
const str = readJsonFile(FILENAME.DIC_BLUEPRT_COMPOSE);
|
||||
const str = readJsonFile(FILENAME.DIC_GUILD_POSITION);
|
||||
let arr = JSON.parse(str);
|
||||
|
||||
export const dicGuildPosition = new Map<number, DicGuildPosition>();
|
||||
|
||||
@@ -102,7 +102,7 @@ export interface DicDonateBase {
|
||||
// 捐献值
|
||||
readonly donateValue: {type: number, count: number}[];
|
||||
// 捐献奖励
|
||||
readonly donateReward: {fund: number, honour: number}[];
|
||||
readonly donateReward: {fund: number, active: number}[];
|
||||
// 今日捐献宝箱领取奖励系数
|
||||
readonly boxRewardRatio: number;
|
||||
}
|
||||
@@ -259,16 +259,16 @@ export function parseDonateValue(str: string) {
|
||||
return result
|
||||
}
|
||||
|
||||
// {"fund": number, "honour": number}
|
||||
// {"fund": number, "active": number}
|
||||
export function parseDonateReward(str: string) {
|
||||
let result = new Array<{ fund: number, honour: number }>();
|
||||
let result = new Array<{ fund: number, active: number }>();
|
||||
if (!str) return result;
|
||||
let decodeArr = decodeArrayListStr(str);
|
||||
for (let [fund, honour] of decodeArr) {
|
||||
if (isNaN(parseInt(fund)) || isNaN(parseInt(honour))) {
|
||||
for (let [fund, active] of decodeArr) {
|
||||
if (isNaN(parseInt(fund)) || isNaN(parseInt(active))) {
|
||||
throw new Error('data table format wrong');
|
||||
}
|
||||
result.push({ fund: parseInt(fund), honour: parseInt(honour) });
|
||||
result.push({ fund: parseInt(fund), active: parseInt(active) });
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user