🐞 fix(辜月集会): 修改失败不在扣除次数、不再给失败奖励

This commit is contained in:
zhangxk
2023-10-23 19:12:25 +08:00
parent e208e750c3
commit ddff1e1d46
2 changed files with 2 additions and 2 deletions

View File

@@ -92,7 +92,7 @@ export class NovemberHandler {
if (playerData.playCnt >= playerData.freeCnt + playerData.buyCnt) return resResult(STATUS.ACTIVITY_NOVEMBER_NO_NUM);
let rewards: string = playerData.successRewards;
if (!isSuccess) rewards = playerData.failRewards;
if (!isSuccess) rewards = '&';//playerData.failRewards;
let playerRecord = await ActivityNovemberRecModel.gameEnd(serverId, activityId, playerData.roundIndex, roleId, gameCode, isSuccess, new Date(), rewards, true);
if (!playerRecord) return resResult(STATUS.ACTIVITY_NOVEMBER_GAMECODE_NOT_FOUND);
playerData = await getPlayerNovemberData(activityId, serverId, roleId);

View File

@@ -74,7 +74,7 @@ export class NovemberData extends ActivityBase {
for (const data of playerData.records) {
let { todayIndex, isSuccess, hasPass } = data;
if (todayIndex == this.todayIndex && isSuccess) this.todayPlayCnt++;
if (hasPass) this.playCnt++;
if (isSuccess) this.playCnt++;
}
}
}