• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 38 项符合查询结果, 库内数据总量为 30,724 项。 (搜索耗时: 0.0039 秒)

31. socket大型项目回调 [ 72%]

...loat': //Float32Array // var floats:Laya.Byte = new Laya.Byte(); // floats.endian = Laya.Byte.LITTLE_ENDIAN; // floats.getFloat32(value); // buffer.writeArrayBuffer(floats); Pomelo.writeBytes(this.encodeFloat(value),buffer); break; case 'double': // var doubles:Laya.Byte = new Laya.Byte(); // double...

来源: Laya_社区 发布时间: 20180119

32. websocket无法连接 [ 72%]

... this.socket = new Laya.Socket(); //这里我们采用大端 this.socket.endian = Laya.Byte.BIG_ENDIAN; this.socket.connectByUrl("ws://"+host+":"+port+"/hoopster"); //建立连接 this.socket.on(Laya.Event.OPEN, this, onOpen); this.socket.on(Laya.Event.MESSAGE, this, onReceive); this.socket.on(Laya....

来源: Laya_社区 发布时间: 20180312

33. 网络通信 · LayaAir3.0文档 · LAYABOX [ 71%]

...声明一个临时Byte类型 var by:Laya.Byte = new Laya.Byte(); //设置endian; by.endian = Laya.Byte.LITTLE_ENDIAN; //写入一个int32数据 by.writeInt32(5000); //写入一个uint16 数据 by.writeUint16(16); //把临时字节数据的数据写入byte中,这里注意写入的是by.buffer; th...

来源: Laya3.0_文档 发布时间: 20230719

34. socket通讯返回数据 [ 71%]

....WebGL); this.byte = new Laya.Byte(); //这里我们采用小端 this.byte.endian = Laya.Byte.LITTLE_ENDIAN; this.socket = new Laya.Socket(); //这里我们采用小端 this.socket.endian = Laya.Byte.LITTLE_ENDIAN; //建立连接 this.socket.connectByUrl("ws://localhost:8899"); this.socket.on(Laya.E...

来源: Laya_社区 发布时间: 20180211

35. HTTP以POST发送Byte字节流,服务器无法解析 [ 71%]

...(Event.ERROR, this, onHttpRequestError); var buffBody=new Byte(); buffBody.endian=Byte.BIG_ENDIAN; buffBody.writeInt32(9); buffBody.writeInt32(100); buffBody.writeByte(1); conn.send("http://10.0.1.139:9000", buffBody.buffer, "post", "arraybuffer",null); } Byte的length长度输出为9 对面的JAVA...

来源: Laya_社区 发布时间: 20160726

36. ts加密md5码封装 [ 62%]

...addingStr.concat(arr); return isArray ? result : result.join(""); } little_endian(charCode: number) { return this.split(this.padding(charCode.toString(16), 8, "0", false), 2).reverse().join(""); } range(...args: number[]) { const start: number = args.length === 1 ? 0 : args[0]; const end: number = a...

来源: Laya_社区 发布时间: 20190321

37. socket无法连接服务器 [ 62%]

...t._instance = new NetSocket();                 NetSocket._instance.endian = laya.net.Socket.LITTLE_ENDIAN;                 NetSocket._instance.initSocket();             }             return NetSocket._instance;         }         private state_: EConnectionState = ...

来源: Laya_社区 发布时间: 20170602

38. LayaAir能做RPG吗?不要问我能不能,因为我已经在做 - 杀意来袭 [ 26%]

...面读取的时候怎么都是错位的 ,原因很简单,源于bytes.endian,laya的bytes的字节顺序默认是的低位读取,而大部分语言默认的是高位读取,api描述里面毫无描述。我已经不止一次的吐槽api了,解决方案bytes.endian = Laya.Byte.BIG_ENDIAN;...

来源: Laya_社区 发布时间: 20161109