diff --git a/game-server/app/servers/activity/handler/gachaHandler.ts b/game-server/app/servers/activity/handler/gachaHandler.ts index 6af590043..0ab34f64d 100644 --- a/game-server/app/servers/activity/handler/gachaHandler.ts +++ b/game-server/app/servers/activity/handler/gachaHandler.ts @@ -73,7 +73,7 @@ export class GachaHandler { if (!dicGacha.count.includes(count)) return resResult(STATUS.WRONG_PARMS); let userGacha = await UserGachaModel.findByRole(roleId, gachaId, activityId); - let { floor, freeCount, hope, point, pickHero, refFreeTime, count: historyCount } = await refreshGacha(dicGacha, userGacha); + let { floor, freeCount, hope, pickHero, count: historyCount } = await refreshGacha(dicGacha, userGacha); if((gachaId == GACHA_ID.ASSIGN|| gachaId == GACHA_ID.TIMELIMIT) && !pickHero) return resResult(STATUS.GACHA_NOT_ASSIGN); let userHeroes = await HeroModel.findByRole(roleId); diff --git a/game-server/app/services/gachaService.ts b/game-server/app/services/gachaService.ts index aff866f0a..79c8113dd 100644 --- a/game-server/app/services/gachaService.ts +++ b/game-server/app/services/gachaService.ts @@ -136,9 +136,9 @@ function countFloorPercent(id: number, floor: Floor[]) { function getHeroQuality(id: number) { if(id == GACHA_FLOOR_TYPE.PURPLE) { return HERO_QUALITY_TYPE.PURPLE; - } else if (GACHA_FLOOR_TYPE.GOLD) { + } else if (id == GACHA_FLOOR_TYPE.GOLD) { return HERO_QUALITY_TYPE.GOLD; - } else if (GACHA_FLOOR_TYPE.ASSIGN) { + } else if ( id == GACHA_FLOOR_TYPE.ASSIGN) { return 0 } else { return false;