任务:排查及修复

This commit is contained in:
luying
2021-11-17 18:09:03 +08:00
parent 2b157c9ef4
commit 08fffc2b54
5 changed files with 24 additions and 21 deletions

View File

@@ -79,7 +79,7 @@ export async function checkTaskWithHeroes(roleId: string, taskType: number, hero
let pushMessage = new Array<TaskListReturn>();
for (let hero of heroes) {
let singlePush = await checkTaskWithHero(roleId, taskType, hero, []);
pushMessage.concat(singlePush);
pushMessage.push(...singlePush);
}
return pushMessage
}
@@ -342,7 +342,7 @@ export async function checkTaskRec(roleId: string, type: number, group: number,
let checkHistory = false; // 是否检查历史
switch (taskType) {
case TASK_TYPE.ROLE_TITLE:
isMatch = taskParam[0] == param.title;
isMatch = param.title >= taskParam[0] && param.oldTitle < taskParam[0];
checkHistory = true;
break;
case TASK_TYPE.HERO_STAR_UP:
@@ -369,9 +369,9 @@ export async function checkTaskRec(roleId: string, type: number, group: number,
break;
case TASK_TYPE.EQUIP_BY_HERO:
isMatch = false;
if (param.isPutOn && param.count == taskParam[1]) { // 装上之后达到 +1
if (param.isPutOn == 1 && param.count == taskParam[1]) { // 装上之后达到 +1
isMatch = true;
} else if (!param.isPutOn && param.count < taskParam[1]) { // 脱下后不能达到 -1
} else if (param.isPutOn == -1 && param.count < taskParam[1]) { // 脱下后不能达到 -1
isMatch = true;
}
break;