From 268670e61a183d45253d17c3f559e6f273335a91 Mon Sep 17 00:00:00 2001 From: CMHopeSunshine <277073121@qq.com> Date: Sat, 24 Dec 2022 10:24:34 +0800 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20=E4=BC=98=E5=8C=96=E9=83=A8?= =?UTF-8?q?=E5=88=86=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- LittlePaimon/config/data/类型.json | 15 +++++---------- LittlePaimon/plugins/Paimon_Bind/__init__.py | 11 +++++------ LittlePaimon/plugins/Paimon_Wiki/__init__.py | 2 +- 3 files changed, 11 insertions(+), 17 deletions(-) diff --git a/LittlePaimon/config/data/类型.json b/LittlePaimon/config/data/类型.json index 4464c98..44cd86b 100644 --- a/LittlePaimon/config/data/类型.json +++ b/LittlePaimon/config/data/类型.json @@ -15,8 +15,7 @@ "神里绫人", "妮露", "莱依拉", - "艾尔海森", - "旅行者" + "艾尔海森" ], "法器": [ "丽莎", @@ -98,8 +97,7 @@ "早柚", "鹿野院平藏", "流浪者", - "珐露珊", - "旅行者" + "珐露珊" ], "雷": [ "丽莎", @@ -112,8 +110,7 @@ "八重神子", "久岐忍", "多莉", - "赛诺", - "旅行者" + "赛诺" ], "水": [ "芭芭拉", @@ -145,16 +142,14 @@ "阿贝多", "五郎", "荒泷一斗", - "云堇", - "旅行者" + "云堇" ], "草": [ "柯莱", "提纳里", "纳西妲", "瑶瑶", - "艾尔海森", - "旅行者" + "艾尔海森" ] } }, diff --git a/LittlePaimon/plugins/Paimon_Bind/__init__.py b/LittlePaimon/plugins/Paimon_Bind/__init__.py index 8b79f74..76ded2c 100644 --- a/LittlePaimon/plugins/Paimon_Bind/__init__.py +++ b/LittlePaimon/plugins/Paimon_Bind/__init__.py @@ -114,8 +114,9 @@ async def _(event: MessageEvent, msg: Message = CommandArg()): if not game_info['list']: await ysb.finish('该账号尚未绑定任何游戏,请确认账号无误~', at_sender=True) if not ( - genshin_games := [{'uid': game['game_role_id'], 'nickname': game['nickname']} for game in game_info['list'] - if game['game_id'] == 2]): + genshin_games := [{'uid': game['game_role_id'], 'nickname': game['nickname']} for game in + game_info['list'] + if game['game_id'] == 2]): await ysb.finish('该账号尚未绑定原神,请确认账号无误~', at_sender=True) await LastQuery.update_or_create(user_id=str(event.user_id), defaults={'uid': genshin_games[0]['uid'], @@ -136,11 +137,9 @@ async def _(event: MessageEvent, msg: Message = CommandArg()): 'Cookie无效,请确认是否已过期\n获取cookie的教程:\ndocs.qq.com/doc/DQ3JLWk1vQVllZ2Z1', at_sender=True) elif config.CookieWeb_enable: - await ysb.finish( - bind_tips.format(cookie_web_url=config.CookieWeb_url), at_sender=True) + await ysb.finish(bind_tips_web.format(cookie_web_url=config.CookieWeb_url), at_sender=True) else: - await ysb.finish('获取cookie的教程:\ndocs.qq.com/doc/DQ3JLWk1vQVllZ2Z1\n获取后,使用[ysb cookie]指令绑定', - at_sender=True) + await ysb.finish(bind_tips, at_sender=True) @ysbc.handle() diff --git a/LittlePaimon/plugins/Paimon_Wiki/__init__.py b/LittlePaimon/plugins/Paimon_Wiki/__init__.py index 6bc035a..f9a4d95 100644 --- a/LittlePaimon/plugins/Paimon_Wiki/__init__.py +++ b/LittlePaimon/plugins/Paimon_Wiki/__init__.py @@ -320,7 +320,7 @@ async def _(bot: Bot, event: MessageEvent, state: T_State, type: str = Arg('type for v in value: temp_msg += f'{index}.{v}\n' index += 1 - msg.append({'type': 'node', 'data': {'name': NICKNAME, 'uin': event.self_id, 'content': temp_msg}}) + msg.append({'type': 'node', 'data': {'name': NICKNAME, 'uin': event.self_id, 'content': temp_msg.strip()}}) msg.insert(0, {'type': 'node', 'data': {'name': NICKNAME, 'uin': event.self_id, 'content': f'你要查询哪个的{type}呢?'}}) msg.append({'type': 'node', 'data': {'name': NICKNAME, 'uin': event.self_id,