自定义群组发送消息其他人收不到

hello21st

问题描述

自定义群组发送消息其他人收不到,但发送完之后服务器有日志记录,请问会是哪里的问题?

程序代码或配置

class MsgHandler_SayInClientGroup extends MsgHandlerBase{
    public function processEvent(EventProxy $proxy,$client_id,$message_data)
    {
        ...
        $new_message_json = json_encode($new_message);
        Gateway::sendToGroup($group_id ,$new_message_json);
        ChatMsgDB::getInstance()->logMsg($new_message_json, __CLASS__,__LINE__,__FUNCTION__);
    }
}
MsgHandler_SayInClientGroup::AutoRegister();

[Time:2024-11-13 16:25:02]{"chat_info":"3333#test06#8","time":1731486302,"msg_id":36,"type":"say"}[Type:ChatMsg][ErrorLevel4][Class:Chat\ChatCommon\ChatMsgDB][Function:logMsg][Line:88][IP:127.0.0.1]
[Time:2024-11-13 16:25:08]{"chat_info":"4444#test03#3","time":1731486308,"msg_id":37,"type":"say"}[Type:ChatMsg][ErrorLevel4][Class:Chat\ChatCommon\ChatMsgDB][Function:logMsg][Line:88][IP:127.0.0.1]

操作系统环境及workerman/webman等具体版本

112 2 0
2个回答

可能是其他人没加入分组,或者其他人的连接已经断开

小七他哥

workerman现在都4了,直接升级

×
🔝