mirror of
https://github.com/Lost-MSth/Arcaea-server.git
synced 2025-12-14 08:06:23 +08:00
Fix two small bugs
- Fix a bug that the level of the character can exceed the max level - Fix a bug that the response is incorrect when upgrading the characters by `generic core`
This commit is contained in:
@@ -25,6 +25,7 @@ class Level:
|
||||
if exp >= Constant.LEVEL_STEPS[self.max_level]:
|
||||
self.exp = Constant.LEVEL_STEPS[self.max_level]
|
||||
self.level = self.max_level
|
||||
return None
|
||||
|
||||
a = []
|
||||
b = []
|
||||
|
||||
@@ -100,7 +100,7 @@ def character_exp(user_id, character_id):
|
||||
core.amount = - int(request.form['amount'])
|
||||
core.item_id = 'core_generic'
|
||||
character.upgrade_by_core(user, core)
|
||||
return success_return({'user_id': user.user_id, 'character': [character.to_dict], 'cores': user.cores})
|
||||
return success_return({'user_id': user.user_id, 'character': [character.to_dict()], 'cores': user.cores})
|
||||
|
||||
|
||||
@bp.route('/me/save', methods=['GET']) # 从云端同步
|
||||
|
||||
Reference in New Issue
Block a user