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

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

211. Button和下面的3D物体重叠,点击button,3D物体会同时响应自己的鼠标脚本 [ 55%]

...ne的缘故,点击空白处返回的对象是scene) Laya.stage.on(Laya.Event.CLICK,this,function(e) { if(e.target.name == "scene的名字") { this.isClick = true; //如果点击的是屏幕的空白处,那么让 isClick 为真 } else { this.isClick = false; //如果点击的不是空白处,...

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

212. 动画-旧版骨骼动画 [ 55%]

...("../../res/threeDimen/skinModel/Zombie/old/Zombie.lh")); zombie.once(Laya.Event.HIERARCHY_LOADED, this, function () { zombie.transform.rotation = new Laya.Quaternion(-0.7071068, 0, 0, -0.7071068); zombie.transform.position = new Laya.Vector3(0.3, 0, 0); addSkinComponent(zombie); loadUI(); }); var s...

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

213. popup设置了关闭效果后,窗口关闭但遮罩层没有关掉,请问如何处理 [ 54%]

...Effect = Laya.Handler.create(this, this.hideEffect); this.btnClose.on(Laya.Event.CLICK, this, this.closeDialog); } //关闭 closeDialog(): void { this.close(); } //关闭效果 hideEffect(): void { Laya.Tween.to(this,{y:Laya.stage.height,alpha:0},200,Laya.Ease.linearIn); } //显示效果 showEffect(...

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

214. 区块地图-PerspectiveWall [ 54%]

...WALL; Laya.stage.bgColor = "#232628"; this.createMap(); Laya.stage.on(Laya.Event.CLICK, this, this.onStageClick); } createMap() { const TiledMap = Laya.TiledMap, Rectangle = Laya.Rectangle; this.tiledMap = new TiledMap(); this.tiledMap.createMap("res/tiledMap/perspective_walls.json", new Rectangle(0...

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

215. 关闭指定定时器timer [ 54%]

...器还在继续调用回调,并没有报错。this.StartToRound.on(Laya.Event.CLICK,null,function(){ Laya.timer.loop(10,this,round);//10ms 一秒100次 }); //转动逻辑 function round(){ tlate.rotation+=roundTurnChange(1); console.log(tlate.rotation); } //转动变量变化 function roundTurnCha...

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

216. 微信小游戏分包实战(TypeScript-小游戏适配文档-微信小游戏) [ 54%]

...钮btnA的点击事件,触发后处理 this.GameMain.newUI.btnA.on(Laya.Event.CLICK, this, this.showB); } //显示B页 private showB():void { this.GameMain.showUI(this.ui.bUI,this.GameMain.newUI) //监听按钮btnB的点击事件,触发后处理 this.GameMain.newUI.btnB.on(Laya.Event.CLICK, this...

来源: Laya2.0_文档 发布时间: 20210715

217. Sprite设置mask属性为什么显示是透明的?怎样才能显示正常? [ 54%]

...awRect(0, 0, Laya.stage.width, Laya.stage.height, "#000000"); mask.on(Laya.Event.CLICK,this,chick);   function chick(){ mask.destroy(); gameContainer.destroy(); }   gameContainer.mask=mask; Laya.stage.addChild(gameContainer);  })();  })(); 附件 : --> 2020-06-03 添加评论 免费帖 --> 分...

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

218. clip清除一遍资源后再加载就无法显示了!有demo! [ 54%]

...ebGL); Laya.stage.scaleMode = Stage.SCALE_FULL; Stat.show(); Laya.stage.on(Event.CLICK,this,clickFun); } private function clickFun():void { if( clip == null ){ clip = new Clip("1.png",6,6); Laya.stage.addChild(clip); clip.play(); }else{ clip.dispose(); clip = null; } } 请官方给一个解决方案...

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

219. [LayaAir2] 在使用videoDom创建视频元素后iPad跟iPhone中位置不一样 [ 54%]

...ss VideoDom { htmlvideo:Laya.HtmlVideo; constructor() { Laya.stage.on(Laya.Event.CLICK,this,this.onClick); } onClick(){ this.initVideo(); } initVideo() { this.htmlvideo = new Laya.HtmlVideo(); this.htmlvideo.setSource("https://www.layaair.com/3.x/de ... ot%3B,1); this.htmlvideo.video.addEventListene...

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

220. clip里的WeakObject.I缓存的数据有问题 [ 54%]

...ebGL); Laya.stage.scaleMode = Stage.SCALE_FULL; Stat.show(); Laya.stage.on(Event.CLICK,this,clickFun); } private function clickFun():void { if( clip == null ){ clip = new Clip("1.png",6,6); Laya.stage.addChild(clip); clip.play(); }else{ clip.dispose(); clip = null; } }   2017-11-28 0 0 分享 微...

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