奇遇:刷新规则修复
This commit is contained in:
@@ -131,7 +131,14 @@ export async function getEvent(eventStatus: number, roleId: string, roleName: st
|
||||
|
||||
for(let e of preEvents) {
|
||||
let index = event.findIndex(cur => cur.point == e.point);
|
||||
if(index == -1) event.push(e);
|
||||
if(index == -1) { // 这个位置空着,则塞入
|
||||
event.push(e);
|
||||
} else {
|
||||
let curEvent = event[index];
|
||||
if(curEvent.status == EVENT_RECORD_STATUS.FAIL_RECEIVED || curEvent.status == EVENT_RECORD_STATUS.SUCCESS_RECEIVED) { // 当前的几个已领取,pre的补位
|
||||
event[index] = e;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user