From fd0ea183c2925ae5328df26af8c72d0a6a331d65 Mon Sep 17 00:00:00 2001 From: xtaodada Date: Sun, 12 Dec 2021 00:02:20 +0800 Subject: [PATCH] =?UTF-8?q?yvlu=20=E6=94=AF=E6=8C=81=E4=B8=8D=E5=9B=9E?= =?UTF-8?q?=E5=A4=8D=E6=B6=88=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- list.json | 6 +++--- yvlu.py | 9 +++++++-- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/list.json b/list.json index 8e4ad7a..03f8b31 100644 --- a/list.json +++ b/list.json @@ -682,13 +682,13 @@ }, { "name": "yvlu", - "version": "1.2", + "version": "1.21", "section": "chat", "maintainer": "xtaodada", - "size": "10.3 kb", + "size": "10.4 kb", "supported": true, "des-short": "将回复的消息转换成语录图片", - "des": "将回复的消息转换成语录图片。\n指令:-yvlu -yvlu_" + "des": "将回复的消息或者输入字符串转换成语录图片。\n指令:-yvlu -yvlu_" }, { "name": "antichannelmsg", diff --git a/yvlu.py b/yvlu.py index 9413ed3..53a5151 100644 --- a/yvlu.py +++ b/yvlu.py @@ -112,11 +112,16 @@ async def yv_lu_process_sticker(name, photo, sticker, path): @listener(is_plugin=True, outgoing=True, command=alias_command("yvlu"), - description="将回复的消息转换成语录") + description="将回复的消息或者输入的字符串转换成语录") async def yv_lu(context): reply = await context.get_reply_message() if not reply: - return await context.edit('你需要回复一条消息。') + message = context.arguments + if message: + await context.edit(message) + reply = context + else: + return await context.edit('你需要回复一条消息或者输入一串字符。') async with bot.conversation('QuotLyBot') as conversation: try: send_for = await reply.forward_to(conversation.chat_id)