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

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

51. 场景管理 · LayaAir3.0文档 · LAYABOX [ 64%]

...完毕,此方法只执行一次 */ onAwake(): void { this.uiBtn.on(Laya.Event.CLICK, this, () => { //点击后,打开Msg场景 Laya.Scene.open("Msg.ls", false, { "text": "点击成功!" }); }); } } 其中,Scene场景有一个Button组件,需要在IDE中,将其拖入到@property暴露...

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

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

...接 this.socket.connectByUrl("ws://45.78.**.**:3000"); this.socket.on(Laya.Event.OPEN, this, openHandler); this.socket.on(Laya.Event.MESSAGE, this, receiveHandler); this.socket.on(Laya.Event.CLOSE, this, closeHandler); this.socket.on(Laya.Event.ERROR, this, errorHandler); function openHandler(event)...

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

53. websocket连接出错 [ 64%]

...03:8888"); // this.socket.connect("10.10.1.103",8888); this.socket.on(Laya.Event.OPEN, this, openHandler); //建立连接 this.socket.on(Laya.Event.MESSAGE, this, receiveHandler); //接收到数据触发函数 this.socket.on(Laya.Event.CLOSE, this, closeHandler); //关闭事件 this.socket.on(Laya.E...

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

54. 浏览器失去焦点的时候能强制保持帧频吗? [ 64%]

... */ //*/强迫保持原本设定的FPS try { sound = new Sound(); sound.addEventListener(SampleDataEvent.SAMPLE_DATA,onWakeUp); channel = sound.play(); }catch(error:Error){}; //*/ } protected function onWakeUp(event:SampleDataEvent):void { event.data.position = event.data.length = 4096 * 4; } 这是...

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

55. 如何与服务端建立连接 [ 63%]

...t + ":" + port; let socket:Laya.Socket = new Laya.Socket(); socket.on(Laya.Event.OPEN,this,()=>{ console.log("connect success!"); }) socket.connectByUrl(url);点此查看Socket官方示例 2018-05-15 1 0 分享 微博 QZONE 微信 rabbit 赞同来自: 只要前端的,还是要前端和后端代...

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

56. macOS sierra 1.7.9 正式版 无法发布资源 [ 63%]

...sion denied at ChildProcess.exithandler (child_process.js:223) at emitTwo (events.js:106) at ChildProcess.emit (events.js:191) at maybeClose (internal/child_process.js:885) at Socket.<anonymous> (internal/child_process.js:334) at emitOne (events.js:96) at Socket.emit (events.js:188) at Pipe._h...

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

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

...; a.pos(200, 200); a.mouseEnabled = true; a.mouseThrough = true; a.on(Laya.Event.MOUSE_DOWN, null, function (e: Laya.Event): void {     console.log("touch a"); } 因为需要将mouseThrough=true才可以,蛋疼的api描叙你能相信是这个熟悉么? “mouseThrough : Boolean = false,指...

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

58. video.on('complete', this, onPlayEnd);视频播完为何不触发“complete”? [ 62%]

...ayEnd);视频播完为何不触发“complete”? function onPlayEnd(evt:Event){ trace("video complete"); } 为何视频播完不触发呢? http://layaair.ldc.layabox.com ... Video 这里要是可以调试该多好~ 2017-01-16 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相...

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

59. 服务器websocket c++发送二进制类型包,客户端没有任何事件响应 [ 62%]

...t.endian = Byte.LITTLE_ENDIAN;//这里我们采用小端; socket.on(Laya.Event.OPEN, this, onSocketOpen); socket.on(Laya.Event.CLOSE, this, onSocketClose); socket.on(Laya.Event.MESSAGE, this, onMessageReveived); socket.on(Laya.Event.ERROR, this, onConnectError); 2017-08-22 0 1 分享 微博 QZONE ...

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

60. js socket 连接不上 [ 62%]

...03:8888"); // this.socket.connect("10.10.1.103",8888); this.socket.on(Laya.Event.OPEN, this, openHandler); //建立连接 this.socket.on(Laya.Event.MESSAGE, this, receiveHandler); //接收到数据触发函数 this.socket.on(Laya.Event.CLOSE, this, closeHandler); //关闭事件 this.socket.on(Laya.E...

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