From fb090839d6bcbb237a33e63b3d9f0b81b37f633c Mon Sep 17 00:00:00 2001 From: himawari <54976075+guohuiyuan@users.noreply.github.com> Date: Wed, 3 Sep 2025 17:07:09 +0800 Subject: [PATCH] =?UTF-8?q?feat(crypter):=20=E6=B7=BB=E5=8A=A0=E8=AF=AD?= =?UTF-8?q?=E9=9F=B3=20(#1197)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugin/crypter/handlers.go | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/plugin/crypter/handlers.go b/plugin/crypter/handlers.go index e194e4b5..1cec8a47 100644 --- a/plugin/crypter/handlers.go +++ b/plugin/crypter/handlers.go @@ -2,6 +2,8 @@ package crypter import ( + "github.com/FloatTech/AnimeAPI/airecord" + "github.com/sirupsen/logrus" zero "github.com/wdvxdr1123/ZeroBot" "github.com/wdvxdr1123/ZeroBot/message" ) @@ -10,7 +12,14 @@ import ( func houEncryptHandler(ctx *zero.Ctx) { text := ctx.State["regex_matched"].([]string)[1] result := encodeHou(text) - ctx.SendChain(message.Text(result)) + logrus.Infoln("[crypter] 回复内容:", result) + recCfg := airecord.GetConfig() + record := ctx.GetAIRecord(recCfg.ModelID, recCfg.Customgid, result) + if record != "" { + ctx.SendChain(message.Record(record)) + } else { + ctx.SendChain(message.Text(result)) + } } func houDecryptHandler(ctx *zero.Ctx) {