利用tp5自带的thphp-queue redis扩展发送消息,在cmd运行命令后报错如下图,注意:Gateway::sendToClient是没有报错,能够成功发送消息,但是Gateway::sendToGroup就发送失败,报错了,如下图 还有的就是,sendToClient和sendToGroup在其他地方是没有问题的能够成功发送消息,而且也验证了发送组ID(roomId),数据类型也是一样的int类型...
Timer::add(8, function () use (&$roomId){ Loader::controller('aa/bb')->cc($roomId); } },,false); 补充截图 ...
根据官方文档 http://doc.workerman.net/protocols/example.html, 客户端传输的数据包样本:1001{"userName":"okXU70-dcPj8wBF4-Da4xhhfQXfs","pass":"123456","loginKey":"R2A4PF34"} 其中t是1001;i是{"userName":"okXU70-dcPj8wBF4-Da4xhhfQXfs","...
客户端发送给workerman的代码,其中参数t=1001,i={"userName":"okXU70-dcPj8wBF4-Da4xhhfQXfs","pass":"123456","loginKey":"R2A4PF34"} this.bytes.endian = Laya.Byte.BIG_ENDIAN, this.bytes.writeUTFBytes(i), this.sendBytes.writeInt32...