🐛 🔥 ascii2d返回多结果&修复合并转发

This commit is contained in:
fumiama
2022-02-07 20:39:49 +08:00
parent 477868c601
commit 259b29f6e3
6 changed files with 56 additions and 35 deletions

View File

@@ -71,7 +71,6 @@ func init() {
for i := 0; i < t && i < 5; i++ {
cid := gjson.Get(g, `list.`+strconv.Itoa(i)+`.CardID`).String()
cachefile := cachedir + cid
imgcq := `[CQ:image,file=` + "file:///" + cachefile + `]`
if file.IsNotExist(cachefile) {
data, err := web.ReqWith(
`https://res.fbigame.com/hs/v13/`+cid+`.png?auth_key=`+
@@ -81,7 +80,7 @@ func init() {
err = os.WriteFile(cachefile, data, 0644)
}
if err != nil {
imgcq = err.Error()
continue
}
}
sk = append(
@@ -89,7 +88,7 @@ func init() {
message.CustomNode(
zero.BotConfig.NickName[0],
ctx.Event.SelfID,
imgcq, // 图片
[]message.MessageSegment{message.Image("file:///" + cachefile)}, // 图片
),
)
}