diff --git a/game-server/app/services/battleService.ts b/game-server/app/services/battleService.ts index ba28e63ab..4cc820b50 100644 --- a/game-server/app/services/battleService.ts +++ b/game-server/app/services/battleService.ts @@ -74,7 +74,7 @@ export function getTowerHeroCe(warId: number, heroes: HeroType[], recHeroes: num let dicWar = gameData.war.get(warId); let heroNum = 0, heroesCeSum = 0; for(let hero of heroes) { - if(recHeroes.indexOf(hero.hid) == -1 && !checkForbiddenChar(hero.hid, hero.job, dicWar.fobiddenCharactor)) { + if(recHeroes.indexOf(hero.hid) == -1 && !checkForbiddenChar(hero.skinId, hero.job, dicWar.fobiddenCharactor)) { heroNum++; heroesCeSum += hero.ce; } @@ -207,8 +207,8 @@ export async function checkTowerWar(roleId: string, battleId: number, seqIds: nu return { status: -1, resResult: resResult(STATUS.TOWER_DUPLICATE_HERO) }; } } - for(let {hid, job} of heroes) { - if(checkForbiddenChar(hid, job, fobiddenCharactor)) { + for(let {skinId, job} of heroes) { + if(checkForbiddenChar(skinId, job, fobiddenCharactor)) { return { status: -1, resResult: resResult(STATUS.TOWER_HERO_FORBIDDEN) }; } }