feat: 添加帮助功能
This commit is contained in:
@@ -2,9 +2,11 @@ package wsclient
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"log"
|
||||
"net/url"
|
||||
|
||||
"git.lxtend.com/qqbot/action"
|
||||
"git.lxtend.com/qqbot/constants"
|
||||
"git.lxtend.com/qqbot/handler"
|
||||
"git.lxtend.com/qqbot/model"
|
||||
@@ -70,6 +72,9 @@ func (c *WebSocketClient) receiveMessages() {
|
||||
go func() {
|
||||
reply := handler.MsgInHandler(msg)
|
||||
if reply.ReplyMsg != "" {
|
||||
if reply.ReferOriginMsg {
|
||||
reply.ReplyMsg = fmt.Sprintf("%s%s", action.GenReply(reply.FromMsg.OriginMsgId, "", 0, 0, 0), reply.ReplyMsg)
|
||||
}
|
||||
sendPkg := model.GenSendPkg(reply.FromMsg.UserId, reply.FromMsg.GroupInfo.GroupId, reply.ReplyMsg, false)
|
||||
sendPkgJson, err := json.Marshal(sendPkg)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user