summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKyomotoi <[email protected]>2022-07-19 11:58:24 +0800
committerKyomotoi <[email protected]>2022-07-19 11:58:24 +0800
commitf9fe488a2b32bd262092a22b2476e75cfaa5f7c9 (patch)
tree25a4b462a3916cb96584dfbdc75b0ba84eefdfd2
parentfc59901a2d527928c8a5be9e6a9557bda0518538 (diff)
downloadATRI-f9fe488a2b32bd262092a22b2476e75cfaa5f7c9.tar.gz
ATRI-f9fe488a2b32bd262092a22b2476e75cfaa5f7c9.tar.bz2
ATRI-f9fe488a2b32bd262092a22b2476e75cfaa5f7c9.zip
🚑️ 补全命令触发
-rw-r--r--ATRI/plugins/anti_effort/__init__.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/ATRI/plugins/anti_effort/__init__.py b/ATRI/plugins/anti_effort/__init__.py
index febfdda..fe8e72a 100644
--- a/ATRI/plugins/anti_effort/__init__.py
+++ b/ATRI/plugins/anti_effort/__init__.py
@@ -31,6 +31,7 @@ async def _add_user(matcher: Matcher, args: Message = CommandArg()):
@add_user.got("waka_url", _GET_URL_MSG)
+@add_user_cmd.got("waka_url", _GET_URL_MSG)
async def _deal_add_user(
event: GroupMessageEvent, _url: str = ArgPlainText("waka_url")
):
@@ -41,10 +42,12 @@ async def _deal_add_user(
await add_user.finish(result)
-user_leave = AntiEffort().cmd_as_group("leave", "退出卷王统计榜")
+user_leave = AntiEffort().on_command("!我不卷了", "退出卷王统计榜")
+user_leave_cmd = AntiEffort().cmd_as_group("leave", "退出卷王统计榜")
@user_leave.handle()
+@user_leave_cmd.handle()
async def _user_leave(event: GroupMessageEvent):
group_id = event.group_id
user_id = event.user_id