本地目录测试 #46

Merged
QAQ merged 1 commits from QAQ into master 2025-05-24 11:19:55 +08:00
2 changed files with 5 additions and 3 deletions

BIN
M.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

View File

@ -399,11 +399,13 @@ class MyPlugin(Star):
else:
yield "获取骚话失败"
@filter.command("语音测试")
@filter.command("本地目录测试")
async def Juno(self, event: AstrMessageEvent):
path = "./Get.wav" # 暂时只接受 wav 格式,其他格式请自行转换
path = "./M.png" # 暂时只接受 wav 格式,其他格式请自行转换
chain = [
Comp.Record(file=path, url=path)
Comp.At(qq=event.get_sender_id()), # At 消息发送者
Comp.Plain("来看这个图:"),
Comp.Image.fromFileSystem(path), # 从本地文件目录发送图片
]
yield event.chain_result(chain)