🐛 Fix 绫华、莫娜天赋

This commit is contained in:
CMHopeSunshine 2022-08-25 15:11:33 +08:00
parent 45dd4f07aa
commit 9c17172627
3 changed files with 8 additions and 7 deletions

View File

@ -328,13 +328,13 @@ class Character(Model):
data['skillLevelMap'][
list(data['skillLevelMap'].keys())[score_talent_map['Talent'][role_name][1]]] += 3
if character.name in ['神里绫华', '莫娜']:
del data['skillLevelMap'][list(data['skillLevelMap'].keys())[2]]
character.talents = Talents(talent_list=[Talent(name=role_skill_map['Name'][talent],
level=data['skillLevelMap'][talent],
icon=role_skill_map['Icon'][talent]) for talent in
data['skillLevelMap']])
if character.name == '神里绫华':
character.talents[0], character.talents[-1] = character.talents[-1], character.talents[0]
character.talents[2], character.talents[-1] = character.talents[-1], character.talents[2]
if character.name == '安柏':
character.talents[0], character.talents[-1] = character.talents[-1], character.talents[0]
if character.name in ['', '']:
@ -447,9 +447,7 @@ class Character(Model):
data['skill_list'][score_talent_map['Talent'][role_name][0]]['level_current'] += 3
if len(data['talentIdList']) >= 5:
data['skill_list'][score_talent_map['Talent'][role_name][1]]['level_current'] += 3
if character.name in ['莫娜', '神里绫华']:
del data['skill_list'][2]
talents_list = data['skill_list'][:3]
talents_list = data['skill_list']
if character.name == '达达利亚':
talents_list[0]['level_current'] += 1
character.talents = Talents(talent_list=[Talent(name=t['name'],

View File

@ -108,6 +108,8 @@ async def draw_chara_card(info: Character):
'center')
await card.crop((0, 0, card.width, 435))
else:
if info.name in ['神里绫华', '莫娜']:
info.talents.pop(2)
await card.draw_rounded_rectangle((69, 380, 145, 452), 8, talent_color[info.talents[0].level - 1][1])
await card.draw_rounded_rectangle((71, 382, 143, 450), 8, talent_color[info.talents[0].level - 1][0])
await card.text(str(info.talents[0].level), (71, 143), 392, fm.get('bahnschrift_bold', 48),

View File

@ -140,7 +140,8 @@ async def draw_chara_detail(uid: str, info: Character):
# 天赋
base_icon = await load_image(ENKA_RES / f'图标_{info.element}.png', mode='RGBA')
base_icon_grey = await load_image(ENKA_RES / '图标_灰.png', mode='RGBA')
if info.name in ['神里绫华', '莫娜']:
info.talents.pop(2)
for i in range(3):
await img.paste(base_icon.resize((132, 142)), (551 + i * 176, 633))
await img.text(str(info.talents[i].level),