寻宝:boss 血量深拷贝
This commit is contained in:
@@ -606,6 +606,7 @@ export class ComBattleHandler {
|
||||
let res = await decreaseItems(teamStatus.capId, sid, [{id: teamStatus.blueprtId, count: 1}]);
|
||||
if (res === true) return resResult(STATUS.COM_BATTLE_BLUEPRT_NOT_ENOUGH);
|
||||
}
|
||||
clearRobotHurtTimer(teamStatus, this.robotHurtTimer);
|
||||
channel.pushMessage('onTeamComplete', resResult(STATUS.SUCCESS, {teamCode, result}));
|
||||
this.teamMap.delete(teamCode);
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@ import { HangUpSpdUpRecModel } from '../db/HangUpSpdUpRec';
|
||||
import { TowerTaskRecModel } from '../db/TowerTaskRec';
|
||||
import { setRank } from './redisService';
|
||||
import { RankParam } from '../pubUtils/interface';
|
||||
import { cloneDeep } from 'lodash';
|
||||
|
||||
export async function checkTowerWar(roleId: string, battleId: number, heroes: Array<number>) {
|
||||
const battleIdStr = `${battleId}`;
|
||||
@@ -386,5 +387,5 @@ export function transBossHpArr(source: Array<{dataId: number, hp: number, actorI
|
||||
let { hp } = elem;
|
||||
desArr.push(Object.assign(elem, {curHp: hp}));
|
||||
});
|
||||
return desArr;
|
||||
return cloneDeep(desArr);
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
"@types/bluebird": "^3.5.19",
|
||||
"@types/chai": "^4.2.14",
|
||||
"@types/crc": "^3.4.0",
|
||||
"@types/lodash": "^4.14.168",
|
||||
"@types/mocha": "^8.2.0",
|
||||
"@types/mongoose": "^5.7.36",
|
||||
"@types/node": "8.10.54",
|
||||
|
||||
Reference in New Issue
Block a user