From 32e9a782dc7bd6f6d3a40b0ee0d48ff58e4039ba Mon Sep 17 00:00:00 2001 From: luying Date: Fri, 4 Dec 2020 13:57:21 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=88=E6=88=90=E8=97=8F=E5=AE=9D=E5=9B=BE?= =?UTF-8?q?=E4=B8=8D=E6=B6=88=E8=80=97=E5=85=83=E5=AE=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../app/servers/battle/handler/comBattleHandler.ts | 10 +--------- shared/consts/consts.ts | 3 +-- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/game-server/app/servers/battle/handler/comBattleHandler.ts b/game-server/app/servers/battle/handler/comBattleHandler.ts index 97890399e..9951cc1f0 100644 --- a/game-server/app/servers/battle/handler/comBattleHandler.ts +++ b/game-server/app/servers/battle/handler/comBattleHandler.ts @@ -770,12 +770,6 @@ export class ComBattleHandler { if(originalSum != dicCompose.blueprtNum) { return resResult(STATUS.COM_BLUEPRT_COUNT_ERROR); } - // 检查元宝 - const role = await RoleModel.findByRoleId(roleId); - const costGold = calculateNum(GOLD_COST_RATIO.BLUEPRT_COMPOSE_COST, {num: originalQuality}, 1000); - if(!role || role.gold < costGold) { - return resResult(STATUS.TOWER_GOLD_NOT_ENOUGH); - } // 添加寻宝币 original.push({ id: CURRENCY_BY_TYPE.get(CURRENCY_TYPE.TREASURE_POINT), @@ -786,8 +780,6 @@ export class ComBattleHandler { if(!rec) { return resResult(STATUS.BATTLE_CONSUMES_NOT_ENOUGH); } - // 消耗元宝 - await RoleModel.costGold(roleId, costGold); const targetList = getBluePrtByQuality(dicCompose.targetQuality); const target = getRandomByLen(targetList); @@ -795,6 +787,6 @@ export class ComBattleHandler { const goods = await handleReward(roleId, roleName, reward); - return resResult(STATUS.SUCCESS, { ...goods, costGold }); + return resResult(STATUS.SUCCESS, { ...goods, costGold: 0 }); } } diff --git a/shared/consts/consts.ts b/shared/consts/consts.ts index bada84eb3..928785b29 100644 --- a/shared/consts/consts.ts +++ b/shared/consts/consts.ts @@ -257,8 +257,7 @@ export const GOLD_COST_RATIO = { "TOWER_HANG_SPDUP": { "A": 0, "B": 50 }, // 天梯挂机加速花费 "TOWER_TASK_REF": { "A": 0, "B": 50 }, // 天梯派遣刷新花费 "DAILY_REF_NUM": { "A": 50, "B": 0 }, // 每日购买次数花费 - "DUNGRON_BUY_NUM": { "A": 0, "B": 50 }, // 秘境购买次数花费 - "BLUEPRT_COMPOSE_COST": { "A": 0, "B": 1000 } // 寻宝合成花费 + "DUNGRON_BUY_NUM": { "A": 0, "B": 50 } // 秘境购买次数花费 } export const EXPRESSION = {