From eadd9656b3415c5bf9470c1dc4f090ef32d83e17 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wuyi=E6=97=A0=E7=96=91?= <444835641@qq.com> Date: Sat, 1 Jan 2022 15:30:03 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=EF=BC=9A=E8=A7=92=E8=89=B2?= =?UTF-8?q?=E5=91=BD=E4=BB=A4=E5=8F=AF=E8=83=BD=E5=87=BA=E9=94=99=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- __init__.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/__init__.py b/__init__.py index 9652838a..8a2a8002 100644 --- a/__init__.py +++ b/__init__.py @@ -317,7 +317,7 @@ async def _(bot:HoshinoBot, ev: CQEvent): if m == "自动签到": try: - if at and ev.user_id in bot.config.SUPERUSERS: + if at and qid in bot.config.SUPERUSERS: qid = at.group(1) elif at and at.group(1) != qid: await bot.send(ev,"你没有权限。",at_sender=True) @@ -332,7 +332,7 @@ async def _(bot:HoshinoBot, ev: CQEvent): await bot.send(ev,"未绑定uid信息!",at_sender=True) elif m == "推送": try: - if at and ev.user_id in bot.config.SUPERUSERS: + if at and qid in bot.config.SUPERUSERS: qid = at.group(1) elif at and at.group(1) != qid: await bot.send(ev,"你没有权限。",at_sender=True) @@ -357,7 +357,7 @@ async def _(bot:HoshinoBot, ev: CQEvent): if m == "自动签到": try: - if at and ev.user_id in bot.config.SUPERUSERS: + if at and qid in bot.config.SUPERUSERS: qid = at.group(1) elif at and at.group(1) != qid: await bot.send(ev,"你没有权限。",at_sender=True) @@ -372,7 +372,7 @@ async def _(bot:HoshinoBot, ev: CQEvent): await bot.send(ev,"未绑定uid信息!",at_sender=True) elif m == "推送": try: - if at and ev.user_id in bot.config.SUPERUSERS: + if at and qid in bot.config.SUPERUSERS: qid = at.group(1) elif at and at.group(1) != qid: await bot.send(ev,"你没有权限。",at_sender=True) @@ -758,7 +758,7 @@ async def char_wiki(name, mode="char", level=None): im = ','.join(raw_data) elif level: data2 = await GetCharInfo(name, mode) - sp = data2["substat"] + ":" + '%.1f%%' % (data["specialized"] * 100) if data2["substat"] != "元素精通" else data2["substat"] + ":" + str(math.floor(data2["specialized"])) + sp = data2["substat"] + ":" + '%.1f%%' % (data["specialized"] * 100) if data2["substat"] != "元素精通" else data2["substat"] + ":" + str(math.floor(data["specialized"])) im = (data2["name"] + "\n等级:" + str(data["level"]) + "\n血量:" + str(math.floor(data["hp"])) + "\n攻击力:" + str(math.floor(data["attack"])) + "\n防御力:" + str(math.floor(data["defense"])) + "\n" + sp)