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

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

31. timer无法用clear清除的BUG [ 77%]

timer无法用clear清除的BUG 我又试了一下, 当loop函数用this绑定时,clear无法清除 ,clearAll可以清除 public function startLoop() {       Laya.timer.loop(2000,this,this.onLoop.bind(this)); }   private function onLoop():void {     if(this.stop){         Laya...

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

32. 时针缩放问题 [ 77%]

时针缩放问题 能不能让laya.timer.scale为0的同时,界面上的ui动画不暂停。我通过laya.timer.scale暂停游戏后,界面上的ui也跟着暂停了,有没有什么好的解决办法 2020-10-28 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 ...

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

33. Sprite-旋转缩放 [ 76%]

...55, 72); ape.x = Laya.stage.width / 2; ape.y = Laya.stage.height / 2; Laya.timer.frameLoop(1, this, animate); } function animate(e) { ape.rotation += 2; //心跳缩放 scaleDelta += 0.02; var scaleValue = Math.sin(scaleDelta); ape.scale(scaleValue, scaleValue); } })();module laya { import Sprite = L...

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

34. Laya.timer.frameLoop(1, this, onLoop); 的使用问题 [ 76%]

Laya.timer.frameLoop(1, this, onLoop); 的使用问题 使用这个方法 单独浏览器运行和微信扫二维码运行都 没问题 但是放到了小游戏 就一卡一卡一卡一卡 最后卡死了。 2018-07-02 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 ...

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

35. 鼠标交互-Hold [ 75%]

...n onApePress(e) { // 鼠标按下后,HOLD_TRIGGER_TIME毫秒后hold Laya.timer.once(HOLD_TRIGGER_TIME, this, onHold); Laya.stage.on(Event.MOUSE_UP, this, onApeRelease); } function onHold() { Tween.to(ape, { "scaleX": 1, "scaleY": 1 }, 500, Ease.bounceOut); isApeHold = true; } /** 鼠标放开后...

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

36. UI-ProgressBar [ 74%]

...dler = new Handler(this, onChange); Laya.stage.addChild(progressBar); Laya.timer.loop(100, this, changeValue); } function changeValue() { if (progressBar.value >= 1) progressBar.value = 0; progressBar.value += 0.05; } function onChange(value) { console.log("进度:" + Math.floor(value * 100) + "%"...

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

37. Laya2.2.0,官方demo,Iphone Xs Max 14.0 锁屏小游戏卡死 [ 74%]

... '---------'); Laya.stage.renderingEnabled = true//恢复渲染 Laya.updateTimer.resume() //恢复onUpdate Laya.timer.resume(); //恢复时间 Laya.timer.scale = 1; }) window['wx'].onHide(() => { this.event(AppEvent.onHide); this.appStatus = AppEvent.onHide; console.log(this.appStatus, '---------...

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

38. timer无法执行 [ 74%]

timer无法执行 初学菜鸟,自己写了一个刚体碰撞的demo,但是timer下的方法无法执行,求大佬解答,有关代码如下(我是直接在自动生成的GameUI类里头写的):   shootBall方法用来生成球体,直接调用的没有问题的,可以正常执行...

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

39. UI-ProgressBar [ 73%]

..."; this.progressBar.changeHandler = new Handler(this, this.onChange); Laya.timer.loop(100, this, this.changeValue); } changeValue() { if (this.progressBar.value >= 1) { this.progressBar.value = 0; } this.progressBar.value += 0.05; } onChange(value) { console.log("进度:" + Math.floor(value * 100)...

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

40. 无法清除指定定时器 [ 73%]

无法清除指定定时器 发起一个定时器: Laya.timer.loop(1000,this,this.fan); 当执行 Laya.timer.clear(this,this.fan);时, 控制台还是在执行 fan 函数里的代码 2018-05-08 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关...

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