mirror of
https://github.com/PaiGramTeam/PamGram.git
synced 2024-11-16 03:55:26 +00:00
🐛 Fix player card get caption when no weapon
This commit is contained in:
parent
45df5e2cc3
commit
bf11cbed97
@ -111,7 +111,7 @@ class PlayerCards(Plugin):
|
||||
def get_caption(self, character: "Avatar") -> str:
|
||||
tags = [idToRole(character.avatarId), f"等级{character.level}", f"命座{character.rank}"]
|
||||
if equip := character.equipment:
|
||||
weapon_detail = self.wiki_service.light_cone.get_by_id(equip.tid)
|
||||
if weapon_detail := self.wiki_service.light_cone.get_by_id(equip.tid):
|
||||
tags.append(weapon_detail.name)
|
||||
tags.append(f"武器等级{equip.level}")
|
||||
tags.append(f"精{equip.rank}")
|
||||
|
Loading…
Reference in New Issue
Block a user