feat: 启用message中的format_info功能

This commit is contained in:
tcmofashi
2025-05-26 10:40:31 +08:00
parent 20d872130b
commit 2f9718441a
7 changed files with 48 additions and 6 deletions

View File

@@ -26,6 +26,7 @@ class MuteAction(PluginAction):
"当你想回避某个话题时使用",
]
default = True # 不是默认动作,需要手动添加到使用集
associated_types = ["command",'text']
async def process(self) -> Tuple[bool, str]:
"""处理测试动作"""
@@ -41,8 +42,8 @@ class MuteAction(PluginAction):
try:
await self.send_message(
type="text",
data=f"[command]mute,{user_id},{duration}",
type="command",
data={"name": "GROUP_BAN", "args": {"qq_id": f"{user_id}", "duration": f"{duration}"}},
# target = target
)

View File

@@ -18,6 +18,7 @@ class CheckOnlineAction(PluginAction):
"mode参数为type时查看在线系统类型分布",
]
default = False # 不是默认动作,需要手动添加到使用集
associated_types = ["text"]
async def process(self) -> Tuple[bool, str]:
"""处理测试动作"""
@@ -30,9 +31,9 @@ class CheckOnlineAction(PluginAction):
try:
if mode == "type":
await self.send_message("#online detail")
await self.send_message("text", "#online detail")
elif mode == "version":
await self.send_message("#online")
await self.send_message("text", "#online")
except Exception as e:
logger.error(f"{self.log_prefix} 执行online动作时出错: {e}")