1
0
Fork 0

sao: add logging to synthesize_enhancement_hero_log

This commit is contained in:
Hay1tsme 2023-11-12 19:53:36 -05:00
parent a767646361
commit b516da2e6e
1 changed files with 8 additions and 0 deletions

View File

@ -253,11 +253,19 @@ class SaoBase:
if equipmentList:
equipment_data = self.game_data.item.get_user_equipment(req.user_id, x.user_common_reward_id)
if equipment_data is None:
self.logger.error(f"Failed to find equipment {x.user_common_reward_id} for user {req.user_id}!")
continue
hero_exp = int(equipment_data["enhancement_exp"]) + int(synthesize_hero_log_data["log_exp"])
self.game_data.item.remove_equipment(req.user_id, x.user_common_reward_id)
if heroList:
hero_data = self.game_data.item.get_hero_log(req.user_id, x.user_common_reward_id)
if hero_data is None:
self.logger.error(f"Failed to find hero {x.user_common_reward_id} for user {req.user_id}!")
continue
hero_exp = int(hero_data["log_exp"]) + int(synthesize_hero_log_data["log_exp"])
self.game_data.item.remove_hero_log(req.user_id, x.user_common_reward_id)