大约有 139 项符合查询结果, 库内数据总量为 31,580 项。 (搜索耗时: 0.0042 秒)
...直在动 不太适合我们调试代码 我们打开Floor.js 找到 Laya.timer.frameLoop(1, this, this.onLoop); 把这一行代码先给注释了 接着 我们先理一理自己的思路 我们要做玩家踩在地板上 那就要用到碰撞检测 上图中紫色的小点点是 两个物体的 坐...
来源: Laya_社区 发布时间: 20160801
...nt.CLICK, this, onDecreaseAlpha1); //定时执行一次(间隔时间) Laya.timer.once(3000, this, onComplete1); } function onDecreaseAlpha2(e) { //移除鼠标单击事件 button2.off(Event.CLICK, this, onDecreaseAlpha2); //定时执行一次(基于帧率) Laya.timer.frameOnce(60, this, onComplete2)...
来源: Laya_示例 发布时间: 20251209
...已经无效) 关于逻辑贞更新间隔机制、时间和其他一些Timer相关的问题 问题状态 最新活动: 2017-05-22 18:18 浏览: 834 关注: 2 人 cuixueying • 2017-05-22 20:40 要不,你把你可以运行但是报错的例子发我下,我来测试下吧! anlijames • 2017-...
来源: Laya_社区 发布时间: 20170522
...e.width / 2; this.ape.y = Laya.stage.height / 2; this.scaleDelta = 0; Laya.timer.frameLoop(1, this, this.animate); } animate() { this.ape.rotation += 2; //心跳缩放 this.scaleDelta += 0.02; let scaleValue = Math.sin(this.scaleDelta); this.ape.scale(scaleValue, scaleValue); } } new Sprite_RoateAnd...
来源: Laya2.0_示例 发布时间: 20251209
...显示在屏幕之前调用,一般用于延迟计算数据。 Node clearTimer(caller:*, method:Function):void 清理定时器。功能同Laya.timer.clearTimer()。 Node config(w:int, h:int):voidPerfHUD contains(node:Node):Boolean 当前容器是否包含指定的 Node 节点对象 。 Node ...
来源: Laya2.0_api 发布时间: 20190513
... Sprite(); Laya.stage.addChild(sp); //每隔0.05秒出现下张图片 Laya.timer.loop(50,this,onLoop); } private function onLoop():void { //更改texture的纹理,逐一显示不同的image chageTexture(); //如果texture有值,进行绘制并排序 if(texture) { sp.graphics.drawTexture(texture,...
来源: Laya_社区 发布时间: 20161107
...E_SHOWALL; //背景颜色 Laya.stage.bgColor = "#232628"; //帧循环 Laya.timer.frameLoop(1,this,onFrame); } private function onFrame():void { //如果创建对象时间为100帧间隔后 if(createTime>=100) { //每200帧间隔创建30个雪花 for(var i:int=0;i640+20||img1.scaleX(图2-1) 在...
来源: Laya2.0_文档 发布时间: 20210715
...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_示例 发布时间: 20251209
... Laya.timer.once(2000,this,function(){ sk.destroy(true) sk = null; Laya.loader.clearRes("res/sk/cow.sk"); ...
来源: Laya_社区 发布时间: 20180828
...s ); } this.apesCon.pos(Laya.stage.width / 2, Laya.stage.height / 2); Laya.timer.frameLoop(1, this, this.animate); } animate() { this.apesCon.rotation += 1; } } new Sprite_Container();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; import Event = Laya.Event; import Browser = La...
来源: Laya2.0_示例 发布时间: 20251209