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

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

41. [LayaAir3]clickHandler只会执行一次,之后点击不再触发 laya.3.0.9 [ 77%]

...,例如节点被添加到舞台后     onEnable(): void {         console.log("2d gamescene onEnable");                  let btn:Laya.Button = LayaUtil.GetChildByPath(this.owner, "CreatePanel/BtnCreate");                 btn.clickHandler = Laya.Handler.create(this, this.onCl...

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

42. list中加的button不能接收点击事件 求一个list中加button的demo [ 77%]

...}     updateListItem(cell: BagItem, index: number):void{         console.log("3333333333333");         if (cell.useBtn.clickHandler == undefined) {             cell.useBtn.on("click", this, this.onItemUse, [index]);         }     }     onItemUse(index):void{ ...

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

43. 用raycast选取实体,hitresult始终是false [ 77%]

...MouseManager.instance.mouseX; point.y = Laya.MouseManager.instance.mouseY; console.log("rayPoint111 pointx:"+ point.x+" pointy:"+point.y+ " ray.origin.x:"+ray.origin.x+ " ray.origin.y:"+ray.origin.y+ " ray.origin.z:"+ray.origin.z+" ray.direction.x:"+ray.direction.x+" ray.direction.y:"+ray.direction....

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

44. Laya.Tween.to 有没有监听值的变化的方法? [ 76%]

...10 }, 1000, Laya.Ease.linearNone, Laya.Handler.create(this, function (p) { console.log(1) }), Laya.Handler.create(this, function (p) { console.log(p) })); 阿琴 • 2018-06-21 17:36 这样写吗?不对呀连console.log(1)都不输出了 阿琴 • 2018-06-21 11:31 static to(target: any, props: an...

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

45. Text无法识别换行符\n?? [ 74%]

...确实会把该符号识别为普通字符串。 这点我们可以通过console.log看出来。 当我们直接在代码里面定义一个 var a = xxx\nyyy 的时候,log输出是这样的: xxx yyy 而当我们从http请求拿到一个字符串 var b = xxx\nyyy 的时候,log输出是这样的...

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

46. 网络通信 · LayaAir3文档 · LAYABOX [ 74%]

...SS, this, this.processHandler); } private processHandler(data:any): void { console.log("processHandler"); } private errorHandler(error:any): void { console.log("errorHandler"); } private completeHandler(data:any): void { console.log("completeHandler"); } } new LayaSample(); 2.2 GET 上面这个示...

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

47. 请问Laya如果获取Laya.Event.CLICK时间的点击坐标? [ 74%]

...ect.on( Laya.Event.CLICK, this, changeVxVy ); } function changeVxVy( e ){ console.log( e.nativeEvent.offsetX ); console.log( e.nativeEvent.offsetY ); }   我设置了一个矩形,并给这个矩形增加了一个点击事件。 我发现e.nativeEvent.offsetX和e.nativeEvent.offsetY返回相对...

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

48. 关于官方技术文档中《微信飞机大战》实战开发中监听界面是否关闭 [ 73%]

...OSE,this,onClose); /** * 界面关闭 */ private function onClose():void { console.log("GameStart界面关闭!"); //从舞台移除自己 this.removeSelf(); //只加载一次,因此直接消毁自己 this.destroy(); }onClose方法并没走到,控制台没输出,请问是什么问题呢 2018-...

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

49. Spine骨骼动画点击区域偏移 获取不到width height [ 72%]

...e.play("idle", true);         Laya.stage.addChild(sprite);         console.log(sprite.getBounds());           console.log(sprite.width,sprite.height));      } 附件 : --> ZG.zip 2016-11-08 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与...

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

50. 多次加载一个页面出现_$P为null的情况 [ 71%]

...r.getUserGold(); if(gold > 500){ Online.joinGame().then(function(data){ console.log(data); StorageHelper.setDeskNo(data.desk.deskNo); StorageHelper.setDeskSeat(data.ownSeatNo); Laya.stage.destroyChildren(); var playSence = new OnlinePlaySence(data); Laya.stage.addChild(playSence); },function(data...

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