🐛 Bug fix
This commit is contained in:
parent
04ec77f203
commit
85cd202ce8
Binary file not shown.
Before Width: | Height: | Size: 6.7 KiB After Width: | Height: | Size: 6.7 KiB |
79
defs/mys2.py
79
defs/mys2.py
@ -491,59 +491,74 @@ async def draw_pic(uid, message: Message, nickname="1", mode=2, role_level=None)
|
|||||||
text_draw.text((245, 477), str(raw_data['stats']['precious_chest_number']), text_color, genshin_font(24))
|
text_draw.text((245, 477), str(raw_data['stats']['precious_chest_number']), text_color, genshin_font(24))
|
||||||
text_draw.text((245, 528), str(raw_data['stats']['luxurious_chest_number']), text_color, genshin_font(24))
|
text_draw.text((245, 528), str(raw_data['stats']['luxurious_chest_number']), text_color, genshin_font(24))
|
||||||
|
|
||||||
UnderChasmsMaw = ChasmsMaw = mondstadt = liyue = dragonspine = inazuma = offering = dict()
|
under_chasms_maw = chasms_maw = mondstadt = liyue = dragonspine = inazuma = offering = dict()
|
||||||
for i in raw_data['world_explorations']:
|
for i in raw_data['world_explorations']:
|
||||||
if i["name"] == "蒙德":
|
# 蒙德
|
||||||
|
if i["id"] == 1:
|
||||||
mondstadt = i
|
mondstadt = i
|
||||||
elif i["name"] == "璃月":
|
# 璃月
|
||||||
|
elif i["id"] == 2:
|
||||||
liyue = i
|
liyue = i
|
||||||
elif i["name"] == "龙脊雪山":
|
# 龙脊雪山
|
||||||
|
elif i["id"] == 3:
|
||||||
dragonspine = i
|
dragonspine = i
|
||||||
elif i["name"] == "稻妻":
|
# 稻妻
|
||||||
|
elif i["id"] == 4:
|
||||||
inazuma = i
|
inazuma = i
|
||||||
elif i["name"] == "渊下宫":
|
# 渊下宫
|
||||||
|
elif i["id"] == 5:
|
||||||
offering = i
|
offering = i
|
||||||
elif i["name"] == "璃月层岩巨渊":
|
# 璃月层岩巨渊
|
||||||
ChasmsMaw = i
|
elif i["id"] == 6:
|
||||||
elif i["name"] == "璃月层岩巨渊·地下矿区":
|
chasms_maw = i
|
||||||
UnderChasmsMaw = i
|
# 璃月层岩巨渊·地下矿区
|
||||||
|
elif i["id"] == 7:
|
||||||
|
under_chasms_maw = i
|
||||||
|
|
||||||
# 层岩巨渊
|
# 层岩巨渊
|
||||||
text_draw.text((477, 727), str(ChasmsMaw['exploration_percentage'] / 10) + '%', text_color,
|
if chasms_maw:
|
||||||
genshin_font(22))
|
text_draw.text((477, 727), str(chasms_maw['exploration_percentage'] / 10) + '%', text_color,
|
||||||
text_draw.text((523, 753), str(UnderChasmsMaw['exploration_percentage'] / 10) + '%', text_color,
|
genshin_font(22))
|
||||||
genshin_font(22))
|
text_draw.text((500, 782), "lv." + str(chasms_maw['offerings'][0]['level']), text_color, genshin_font(22))
|
||||||
text_draw.text((500, 782), 'lv.' + str(UnderChasmsMaw['offerings'][0]['level']), text_color, genshin_font(22))
|
|
||||||
|
if under_chasms_maw:
|
||||||
|
text_draw.text((523, 753), str(under_chasms_maw['exploration_percentage'] / 10) + '%', text_color,
|
||||||
|
genshin_font(22))
|
||||||
|
|
||||||
# 蒙德
|
# 蒙德
|
||||||
text_draw.text((235, 600), str(mondstadt['exploration_percentage'] / 10) + '%', text_color,
|
if mondstadt:
|
||||||
genshin_font(22))
|
text_draw.text((235, 600), str(mondstadt['exploration_percentage'] / 10) + '%', text_color,
|
||||||
text_draw.text((235, 630), 'lv.' + str(mondstadt['level']), text_color, genshin_font(22))
|
genshin_font(22))
|
||||||
|
text_draw.text((235, 630), 'lv.' + str(mondstadt['level']), text_color, genshin_font(22))
|
||||||
text_draw.text((258, 660), str(raw_data['stats']['anemoculus_number']), text_color, genshin_font(22))
|
text_draw.text((258, 660), str(raw_data['stats']['anemoculus_number']), text_color, genshin_font(22))
|
||||||
|
|
||||||
# 璃月
|
# 璃月
|
||||||
text_draw.text((480, 597), str(liyue['exploration_percentage'] / 10) + '%', text_color,
|
if liyue:
|
||||||
genshin_font(22))
|
text_draw.text((480, 597), str(liyue['exploration_percentage'] / 10) + '%', text_color,
|
||||||
text_draw.text((480, 627), 'lv.' + str(liyue['level']), text_color, genshin_font(22))
|
genshin_font(22))
|
||||||
|
text_draw.text((480, 627), 'lv.' + str(liyue['level']), text_color, genshin_font(22))
|
||||||
text_draw.text((503, 657), str(raw_data['stats']['geoculus_number']), text_color, genshin_font(22))
|
text_draw.text((503, 657), str(raw_data['stats']['geoculus_number']), text_color, genshin_font(22))
|
||||||
|
|
||||||
# 雪山
|
# 雪山
|
||||||
text_draw.text((238, 733), str(dragonspine['exploration_percentage'] / 10) + '%',
|
if dragonspine:
|
||||||
text_color,
|
text_draw.text((238, 733), str(dragonspine['exploration_percentage'] / 10) + '%',
|
||||||
genshin_font(22))
|
text_color,
|
||||||
text_draw.text((238, 764), 'lv.' + str(dragonspine['level']), text_color, genshin_font(22))
|
genshin_font(22))
|
||||||
|
text_draw.text((238, 764), 'lv.' + str(dragonspine['level']), text_color, genshin_font(22))
|
||||||
|
|
||||||
# 稻妻
|
# 稻妻
|
||||||
text_draw.text((750, 588), str(inazuma['exploration_percentage'] / 10) + '%', text_color,
|
if inazuma:
|
||||||
genshin_font(22))
|
text_draw.text((750, 588), str(inazuma['exploration_percentage'] / 10) + '%', text_color,
|
||||||
text_draw.text((750, 616), 'lv.' + str(inazuma['level']), text_color, genshin_font(22))
|
genshin_font(22))
|
||||||
text_draw.text((750, 644), 'lv.' + str(inazuma['offerings'][0]['level']), text_color,
|
text_draw.text((750, 616), 'lv.' + str(inazuma['level']), text_color, genshin_font(22))
|
||||||
genshin_font(22))
|
text_draw.text((750, 644), 'lv.' + str(inazuma['offerings'][0]['level']), text_color,
|
||||||
|
genshin_font(22))
|
||||||
text_draw.text((773, 672), str(raw_data['stats']['electroculus_number']), text_color, genshin_font(22))
|
text_draw.text((773, 672), str(raw_data['stats']['electroculus_number']), text_color, genshin_font(22))
|
||||||
|
|
||||||
# 渊下宫
|
# 渊下宫
|
||||||
text_draw.text((750, 750), str(offering['exploration_percentage'] / 10) + '%', text_color,
|
if offering:
|
||||||
genshin_font(22))
|
text_draw.text((750, 750), str(offering['exploration_percentage'] / 10) + '%', text_color,
|
||||||
|
genshin_font(22))
|
||||||
|
|
||||||
# 家园
|
# 家园
|
||||||
if len(raw_data['homes']):
|
if len(raw_data['homes']):
|
||||||
|
Loading…
Reference in New Issue
Block a user