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

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

1. js飞机大战报错 请大神看看 [ 100%]

...ll.js文件 里面的组件名正确  layaUI.max.all.js:          this.pauseBtn=null;          this.hpLabel=null;          this.levelLabel=null;          this.scoreLabel=null;          this.infoLabel=null; GameInfo.js: var GameInfo = (function (_super) {   ...

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

2. 通过laya设计模式制作的,要怎么给按钮绑定事件呢? [ 91%]

...的链接 提交 2 个回复 Laya_Aaron 赞同来自: on(Event.MOUSE_DOWN,this,onClick); 试一下吧  onclick 函数里再打印log 2017-12-13 0 10 分享 微博 QZONE 微信 Laya_Aaron 赞同来自: 这个进度条 var 为pro 另外一张图的类继承了之前页面发布生成的类,直接...

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

3. playSound和playMusic结束时候有异常抛出 [ 85%]

...usic/Music_start.mp3",                      Laya.Handler.create(this, this.onLoadFinished));     }     onLoadFinished()     {         Laya.SoundManager.playMusic("res/music/Music_start.mp3", 1);     } } new GameMain();   -------------------------------------------------------...

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

4. 针对2.0.0 beta5 setLoadingPage 做增强 [ 84%]

...异步方法 */ export default class LoadPage { constructor(url = null) { this._loadScene = null if (url) this.preload(url) } /** * 预加载loading页面 * @param {String} url loading页面url */ async preload(url = 'loadingpage.scene') { if (this._loadScene && url === this._loadScene.url) ...

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

5. 音频 · LayaAir3.4 · 引擎文档 · LAYABOX [ 79%]

...去舞台焦点(切出游戏)的处理 Laya.stage.on(Laya.Event.BLUR, this, () => { _sound.stop(); }); //获得舞台焦点(切回游戏)的处理 Laya.stage.on(Laya.Event.FOCUS, this, () => { _sound.play(0); }); …… Copyright ©Layabox 2026 all right reserved,powered by LayaAir E...

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

6. 模型与动画的导入使用 · LayaAir3.4 · 引擎文档 · LAYABOX [ 77%]

...("girl/girl.lh").then(res => { let girl : Laya.Sprite3D = res.create(); this.scene3D.addChild(girl); //获得Animator this._animator = girl.getComponent<Laya.Animator>(Laya.Animator); }); this.on( Laya.Event.MOUSE_DOWN, this, this.switchAni ); } switchAni(): void { if (this._isRun) { //播...

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

7. socket大型项目回调 [ 76%]

... = console.log; console.warn = console.log; console.error = console.log; } this._message = new Message(); this._package = new Package(); this.socket = null; this.callbacks = {}; this.handlers = {}; // Map from request id to route this.routeMap = {}; this.heartbeatInterval = 0; this.heartbeatTimeout ...

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

8. layacmd 安装不成功 [ 76%]

... have the latest version of node.js and npm installed. npm ERR! If you do, this is most likely a problem with the electron package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! node install.js npm ERR! You can get information on how to open an issue...

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

9. laya.display.Node_API3.0 [ 75%]

...器。功能同Laya.timer.clearTimer()。 Parameters caller: any 执行域(this)。 method: Function 结束时的回调方法。 Returns void contains contains(node: Node): boolean Defined in laya/display/Node.ts:546 当前容器是否包含指定的 Node 节点对象 。 Parameters node: Node 指...

来源: Laya3.0_api 发布时间: 20231115

10. Steam扩展实例 · LayaAir3.4 · 引擎文档 · LAYABOX [ 73%]

...perty({type: Laya.Button}) public initBtn: Laya.Button; onEnable(): void { this.initBtn.on(Laya.Event.CLICK, this.onInit); } onInit() { alert(extendLib.initializeSteam()); } } 构建发布Windows后,需要在exe的同级目录下,新建一个steam_appid.txt 文件,其中只包含 AppID。 (...

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