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

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

31. laya可以支持滑动手势吗 [ 78%]

...,亦没有光标一说,如果你想做滑动手势,,,可以监听Mouse_MOVE事件,在移动的时候改变光标(移动端可以让显示对象跟随鼠标移动)显示! 2017-06-17 0 0 分享 微博 QZONE 微信 ohkei - as3、as2、h5 赞同来自: 手势识别主要会用到以下...

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

32. MOUSE_UP事件 [ 76%]

..._"+i].on(Event.MOUSE_DOWN,this,this.clickDown) ; this["_role_"+i].on(Event.MOUSE_MOVE,this,this.clickMove); // this["_role_"+i].on(Event.MOUSE_UP,this,this,clickUp); }这样的方式添加监听时,MOUSE_UP不支持对象采用拼接的形式监听?MOUSE_DOWN和MOUSE_MOVE是没有问题的。 20...

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

33. laya拖拽在部分机型(一部XR)StageX不对 [ 71%]

...n(Laya.Event.MOUSE_OUT, this, this.onMouseEvent); Laya.stage.on(Laya.Event.MOUSE_MOVE, this, this.onMouseEvent); //鼠标yi'dong private onMouseEvent(e: Laya.Event): void {         switch (e.type) { case Laya.Event.MOUSE_MOVE:       this.drag.x = e.stageX;       this.drag.y = e.stageY;   ...

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

34. 在微信分享成功的回调函数里,Laya播放音效失败。 [ 70%]

...his.onLoop); //移除舞台的鼠标移动事件 Laya.stage.off(Laya.Event.MOUSE_MOVE); }  //恢复 GameEx.prototype.resume = function () { //在循环中创建敌人 Laya.timer.frameLoop(1,this,this.onLoop); console.log("恢复播放音乐") Laya.SoundManager.stopMusic(); Laya.SoundManager.playMus...

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

35. 怎么移除鼠标监听事件 [ 70%]

...自: VkonSun on用来侦听事件,off用来移除事件,btn.off(Event.MOUSE_MOVE, this, onMouseMove);  2018-03-21 1 0 分享 微博 QZONE 微信 VkonSun 赞同来自: 谢谢 2018-03-21 0 1 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 该问题目前已经被锁定, 无法...

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

36. 文字在框内滑动、滚动文本 [ 70%]

...mouseX;     this.prevY = this.txt.mouseY;     Laya.stage.on(Laya.Event.MOUSE_MOVE, this, this.scrollText);     Laya.stage.on(Laya.Event.MOUSE_UP, this, this.finishScroll); } function finishScroll(){     Laya.stage.off(Laya.Event.MOUSE_MOVE, this, this.scrollText);     Laya.stage.off(Laya.E...

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

37. sprite点击事件 位置便宜 [ 70%]

...useHandler); rect.on(Event.RIGHT_CLICK, this, mouseHandler); rect.on(Event.MOUSE_MOVE, this, mouseHandler); rect.on(Event.MOUSE_OVER, this, mouseHandler); rect.on(Event.MOUSE_OUT, this, mouseHandler); rect.on(Event.DOUBLE_CLICK, this, mouseHandler); rect.on(Event.MOUSE_WHEEL, this, mouseHandler); } ...

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

38. 那个文本溢出需要滚动条怎么弄,API里面就说用Scroll接口,小白 不懂怎么弄 [ 70%]

...vX = this.txt.mouseX;this.prevY = this.txt.mouseY;Laya.stage.on(Laya.Event.MOUSE_MOVE,this,scrollText);Laya.stage.on(Laya.Event.MOUSE_UP,this,finishScrollText);}/* 停止滚动文本 */function finishScrollText(){Laya.stage.off(Laya.Event.MOUSE_MOVE, this, this.scrollText);Laya.stage.off(Laya.Event....

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

39. TypeError: relativePath is undefined [ 68%]

... = Laya.stage.mouseX; mLastMouseY = Laya.stage.mouseY; Laya.stage.on(Event.MOUSE_MOVE, this, mouseMove); } function mouseMove() { //移动地图视口 tiledMap.moveViewPort(mX - (Laya.stage.mouseX - mLastMouseX), mY - (Laya.stage.mouseY - mLastMouseY)); } function mouseUp() { mX = mX - (Laya.stage.m...

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

40. 循环添加一组按钮事件无法正常使用 [ 68%]

...nt.MOUSE_DOWN, this, mouseHandler);                 b.on(Event.MOUSE_MOVE, this, mouseHandler);                 b.on(Event.MOUSE_UP, this, mouseHandler);                 trace("addEvent");             }         }         private function mouse...

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