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

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

791. laya.media.Sound [ 55%]

...rties | Methods Packagelaya.mediaClasspublic class SoundInheritanceSound EventDispatcher Object Sound 类是用来播放控制声音的类。 Public Properties PropertyDefined By  duration : Number[read-only] 获取总时间。 SoundPublic Methods Hide Inherited Public Methods Show Inherited Pu...

来源: laya_api 发布时间: 20170929

792. ani动画问题,cannot read property '_tf' of null [ 55%]

... this.ani1.play(0, false);//出错了             this.ani1.on(Laya.Event.COMPLETE, this, () => {                 this.removeSelf();             });         } 这样播放动画有时候会报错,如附件图,但有时候又不报错 附件 : --> 2017-06-14 添加评...

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

793. 如何对3D精灵进行鼠标检测(JavaScript-3D基础(JS)-LayaAir3D之鼠标交互) [ 55%]

... ```typescript { //在舞台上添加鼠标事件监听 Laya.stage.on(Laya.Event.MOUSE_DOWN,this, this.onMouseDown); } //点击触发事件 onMouseDown() { //记录点击到舞台上的点 this.point.x = Laya.MouseManager.instance.mouseX; this.point.y = Laya.MouseManager.instance.mouseY; //产生射...

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

794. 如何对3D精灵进行鼠标检测(TypeScript-3D基础(TS)-LayaAir3D之鼠标交互) [ 55%]

... ```typescript { //在舞台上添加鼠标事件监听 Laya.stage.on(Laya.Event.MOUSE_DOWN,this, this.onMouseDown); } //点击触发事件 onMouseDown() { //记录点击到舞台上的点 this.point.x = Laya.MouseManager.instance.mouseX; this.point.y = Laya.MouseManager.instance.mouseY; //产生射...

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

795. addchild后,怎么去引用? [ 55%]

...lose_1.ani"); lose1.x=150; lose1.y=400; lose1.size(100,300); lose1.on(Laya.Event.CLICK,this.listP,this.play1); lose1.name="lose1"; this.listP.addChild(lose1); play1():void { console.log("111"); this.lose1.play(); //this._childs[5].play(); } 2017-10-25 添加评论 免费帖 --> 分享 微博 QZONE ...

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

796. 摄像机捕捉目标(JavaScript-3D基础(JS)-LayaAir3D之Camera) [ 55%]

...0, 1, 0); ``` ```typescript //点击事件 this.changeActionButton.on(Laya.Event.CLICK, this, function(){ this.index++; if (this.index % 3 === 1 ){ //摄像机捕捉模型目标 this.camera.transform.lookAt(this.box.transform.position, this._up); } else if (this.index % 3 === 2){ //摄像机捕捉...

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

797. 摄像机捕捉目标(TypeScript-3D基础(TS)-LayaAir3D之Camera) [ 55%]

...0, 1, 0); ``` ```typescript //点击事件 this.changeActionButton.on(Laya.Event.CLICK, this, function(){ this.index++; if (this.index % 3 === 1 ){ //摄像机捕捉模型目标 this.camera.transform.lookAt(this.box.transform.position, this._up); } else if (this.index % 3 === 2){ //摄像机捕捉...

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

798. 我想在动画播放结束后加一个事件,怎么加? [ 55%]

... 个回复 176*****233 赞同来自: geo 监听_ani的完成事件 _ani.on(EVENT.COMPLETE, this, function(){}); 2018-04-28 1 0 分享 微博 QZONE 微信 fool_tiger 赞同来自: 谢谢! 2018-05-02 0 0 分享 微博 QZONE 微信 AlexNine 赞同来自: 可以直接在play后面加个回调 function...

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

799. 微信小游戏默认项目代码添加unity导出.lh文件,微信开发工具提示错误 [ 55%]

...:10) at ResInfo.onLoaded (http://127.0.0.1:51205/game/code.js:12995:61) at EventHandler.__proto.runWith (http://127.0.0.1:51205/game/code.js:711:59) at ResInfo.__proto.event (http://127.0.0.1:51205/game/code.js:483:28) at LoaderManager.__proto._endLoad (http://127.0.0.1:51205/game/code.js:13152:11) ...

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

800. parent加载多个child,parent不响应鼠标事件? [ 55%]

...t不响应鼠标事件? parent加载了child1,child2,child3, parent.on(Event.MOUSE_DOWN, this, function(){     trace("parent被点击了!"); });     其中child1,child2,child3都是load图片的Sprite,为何parent(它也是个Sprite)识别不到鼠标事件? 2017-03-12 添加评论 ...

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