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

大约有 1,013 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0064 秒)

91. 网络和格式-XML [ 83%]

...alue = "item aitem bsomethings..."; this.proessXML(xmlValueContainsError); console.log("\n"); this.proessXML(xmlValue); } // 使用xml proessXML(source) { const Utils = Laya.Utils; let xml; try { xml = Utils.parseXMLFromString(source); } catch (e) { console.log(e.massage); return; } this.printDirect...

来源: Laya2.0_示例 发布时间: 20251130

92. socket通讯返回数据 [ 83%]

...# } private openHandler(event: any = null): void { //正确建立连接; console.log("建立连接");//***************************************************************************不写出 console.log(event); } private receiveHandler(msg: any = null): void { ///接收到数据触发函数 console.l...

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

93. 动态阴影被切割了?为啥没有显示完成的阴影 [ 82%]

...{ var box = scene.addChild(new myCube(0.1, 0.1, 11.5, colorCalc(), 0, 1)); console.log(box); } function addTestBox() { var box = scene.addChild(new myCube(0.1, 0.1, 11.5, colorCalc(), 0, 1)); console.log(box); } function addFirstBox() { var box = scene.addChild(new myCube(1, 1, 0.5, colorCalc(), 0))...

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

94. 我用laya.websocket通信 二进制数据, 服务器对二进制数据进行解析,解析出来不是预期,请问我哪里写错了? 代码如下 [ 82%]

...tr = new String("大家好,这是websocket通信!");             console.log("str.length*2:" + str.length*2);             var b = new ArrayBuffer(20 + str.length*2);             var dv = new DataView(b, 0);             dv.setUint16(0, str.length*2, false);           ...

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

95. socket与node服务端连不上?按照官方案例 [ 82%]

... this, errorHandler); function openHandler(event){ //正确建立连接; console.log("链接"); } function receiveHandler(msg){ ///接收到数据触发函数 console.log("接受"); } function closeHandler(e){ //关闭事件 console.log("关闭"); } function errorHandler(e){ //连接出错 console...

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

96. 加载-加载序列 [ 82%]

...setLoaded), null, null, 2, false); })(); function onAssetLoaded(texture) { console.log(texture.source); // 恢复默认并发加载个数。 if (++numLoaded == 3) { Laya.loader.maxLoader = 5; console.log("All done."); } } })();module laya { import Texture = Laya.Texture; import Handler = Laya.Handle...

来源: Laya_示例 发布时间: 20251130

97. 骨骼动画-适配版Spine [ 82%]

...is.skeleton.on(Event.STOPPED, this, this.play); this.play(); } onError() { console.log("parse error"); } play() { console.log("1111111111"); if (++this.index >= this.skeleton.getAnimNum()) { this.index = 0; } this.skeleton.play(this.index, false, true); } } new SpineBinary;import Browser = Laya.Brow...

来源: Laya2.0_示例 发布时间: 20251130

98. 在微信小游戏真机wx.onShow和wx.onHide中的currTimer的问题 [ 82%]

...er.window.wx.onHide(_onHideWX); } private function _onShowWX(res:*):void { console.log("wx.onShow:",res); console.log(Laya.timer.currTimer); } private function _onHideWX():void { console.log("wx.onHide:"); console.log(Laya.timer.currTimer); } wx.onShow.currTimer == wx.onHide.currTimer 这两个居...

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

99. 我竟然被射线检测这个小功能给难了一天了 [ 82%]

...wner.scene as Laya.Scene3D;   this.physics=scene.physicsSimulation;     console.log("相机位置",(this.owner.getChildByName("Main Camera") as Laya.Sprite3D).transform.position) } onStart(): void {     Laya.stage.on(Laya.Event.MOUSE_DOWN,this,this.onMouseDownCb) } private onMouseDownCb(e:Laya....

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

100. 无法获取音频的时间长度 [ 82%]

...d/dh/gril1.wav", 1,Laya.Handler.create(this,() => {       }));     console.log(soundChItem.position+"");     console.log(soundChItem.duration+""); 附件 : --> 2023-05-19 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提...

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