From d3c69bf2b1e8e78213955e3d45b7bda48b6f1801 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wuyi=E6=97=A0=E7=96=91?= <444835641@qq.com> Date: Mon, 20 Dec 2021 01:03:28 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=EF=BC=9AReadme?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 3 +++ __init__.py | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 7586b0b0..12ccb900 100644 --- a/README.md +++ b/README.md @@ -60,6 +60,8 @@ $ pip3 install -r requirements.txt 新增:`角色xx`命令的类型匹配,例如`角色长柄武器`,可以查看所有长柄武器的角色,例如`角色火`,`角色火元素伤害加成`,`角色琉璃袋`,`角色燃愿玛瑙`等等…… +新增:`材料xx`命令,例如`材料可莉`,可以查看可莉的材料列表。 + 新增:`活动列表`命令,第一次使用可能输出时间略久,需等待一段时间。 新增:`御神签`命令,随机抽签。 @@ -257,6 +259,7 @@ $ pip3 install -r requirements.txt | 角色 | | 查询角色简略信息 | 角色可莉 | | | 角色 | \d | 查询角色某个等级的属性 | 角色可莉64 | | | 角色 | <某种类型> | 匹配一整类角色 | 角色燃愿玛瑙 | | +| 材料 | | 输出角色材料列表 | 材料可莉 | | | 查询词云 | | 查询绑定角色的词云 | 查询词云 | 必须绑定过UID/MYSID | ### 深渊查询: diff --git a/__init__.py b/__init__.py index 920f3263..17068a2e 100644 --- a/__init__.py +++ b/__init__.py @@ -117,7 +117,11 @@ async def _(bot:HoshinoBot, ev: CQEvent): img_path = os.path.join(FILE2_PATH,"event.jpg") while(1): if os.path.exists(img_path): - im = f'[CQ:image,file=file://{img_path}]' + f=open(img_path,'rb') + ls_f = base64.b64encode(f.read()).decode() + imgmes = 'base64://' + ls_f + f.close() + im = f"[CQ:image,file={imgmes}]" break else: await draw_event_pic()