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

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

151. 高级应用-渲染纹理 [ 62%]

....stage.height - 100 * Laya.Browser.pixelRatio); changeActionButton.on(Laya.Event.CLICK, this, function () { layaPlane.getChildAt(0).meshRender.material.diffuseTexture = renderTargetCamera.renderTarget; }); })); } function setMaterials(spirit3D) { if (spirit3D instanceof Laya.MeshSprite3D) { var mesh...

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

152. 鼠标事件能否在有图形的区域感应,特别是子项坐标为负数时(已经找到问题) [ 62%]

...(已经找到问题) package { import laya.display.Sprite; import laya.events.Event; public class MainUi extends Sprite { private var testPan:Sprite; public function MainUi() { super(); this.graphics.drawRect(0,0,500,500,"#fff0cc"); testPan = new Sprite(); testPan.name = "testPan"; this.addChild...

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

153. parameter 2 is not of type 'WebGLTexture'. [ 62%]

..._start = this.getChildByName('btn_start') as Laya.Image; btn_start.on(Laya.Event.CLICK,this,()=>{ // 加载资源足以播放 if(videoElement.readyState == 4){ videoElement.play(); } }); 附件 : --> demo.zip 2020-07-22 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结...

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

154. localToGlobal获取坐标总是错误! [ 62%]

...ByName("boxSpaw"); //this.spriteSpaw.loadImage("../..") buttonTest.on(Laya.Event.CLICK,this,()=>{ let point = new Laya.Point(this.sprteCenter.x,this.sprteCenter.y); let pointGlobal = this.sprteCenter.localToGlobal(point); Laya.stage.addChild(this.boxSpaw); this.boxSpaw.x = pointGlobal.x; this.box...

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

155. Dialog [ 62%]

...ction Controller() {     Controller.super(this);      this.btn.on(Event.CLICK,this,function(){           this.destroy();     })  } Laya.class(Controller, "Controller", stUI); 2018-08-31 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: ...

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

156. worldroot [ 62%]

...hildAt(root, 0);   Laya.Physics.I.worldRoot = root;   Laya.stage.on(Laya.Event.CLICK, this, () => { Laya.Physics.I.worldRoot.x -= 50; });   设置worldRoot = 一个新的sprite后, 移动world root ,物理世界不会跟着一起移动 2018-11-26 添加评论 免费帖 --> 分享 微博 QZ...

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

157. 有没有SoundChannel的示例? [ 62%]

...undChannel = new SoundChannel(); SoundManager.addChannel(channel); _btn.on(Event.CLICK, this, soundClick); function soundClick(evt:Event){ alert("channel.isStoped:"+channel.isStoped); if (channel.isStoped){ channel.play(); }else{ channel.stop(); } } channel.isStoped输出是:undefined 2017-01-16 ...

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

158. UI编辑器里按钮事件 onClick怎么使用 [ 61%]

...using 赞同来自: 求正确用法,  注: 我不想在代码里写btn.on(Event.Click,toLogin) 2017-12-05 0 0 分享 微博 QZONE 微信 Monica - 知识达人 赞同来自: 目前这个功能是用来测试的,我们还要考虑是否保留onClick里边填的方法必须是静态的,具体的...

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

159. 我想给一段文字添加个点击事件,点击后文字会出现放大缩小的效果,要怎样才能实现 [ 61%]

...后在 回调中 写变大的逻辑 伪代码大概这个样子   btn.on(Event.CLICK, this, onBtnClick);    然后 onBtnClick方法里面写放大的逻辑   2018-08-15 0 0 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 发起人 bububu 相关问...

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

160. 鼠标右键监听无效 [ 61%]

...。 是在谷歌浏览器运行的,没有调用test方法 Laya.stage.on(Event.RIGHT_CLICK,this,test) 2019-10-23 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 1 个回复 李友涛 赞同来自: 你好,问题解决了吗 ...

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