大约有 172 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0051 秒)
...air3.3.0-beta.4中2D导航数据清理报错 直接销毁所有子节点(this.roleBox.destroyChildren();)中添加了Laya.Nav2DAgent代理导航时会报错: 比如子节点有三个角色,其中两个角色正在寻路时,第三个角色执行了销毁所有子节点(this.roleBox.des...
来源: Laya_社区 发布时间: 20250707
...射线初始化(必须初始化) //获取鼠标在屏幕空间位置 this.pointRay.x = Laya.MouseManager.instance.mouseX; this.pointRay.y = Laya.MouseManager.instance.mouseY; //详设计产生射线方法,通过2D坐标获取与屏幕垂直的一条射线 console.log( PanelMgr.mainCamera); P...
来源: Laya_社区 发布时间: 20190416
...ublic/test/img/food/f9.png", ]; Laya.loader.load(urls, Handler.create(this, onAssetLoaded), Handler.create(this, onLoading, null, false), Loader.TEXT); 这个样能加载。 但是 var roleAni = new Laya.Animation(); roleAni.loadImages(); roleAni.play(); Laya.stage.addChild(roleAni); ...
来源: Laya_社区 发布时间: 20170718
...有解决方案,以下为示例代码: var sprite= Laya.loader.getRes(this._stlurl) as Laya.Sprite3D; this.skill = Laya.Sprite3D.instantiate(sprite); target.addChild(this.skill); this.Play(); 这种卡顿在PC谷歌浏览器上不明显,但手机上就很明显了,另外在IDE的layaair...
来源: Laya_社区 发布时间: 20180425
...@regClass() export class BloodBar extends BloodBarBase { onAwake(): void { this.bar.value = 1; this.value.visible = false; Laya.stage.on(Laya.Event.CLICK, this, this.onHurt); } onHurt(): void { this.bar.value = this.bar.value - 0.9; this.value.y = 35; this.value.visible = true; Main.instance.animato...
来源: Laya3.0_文档 发布时间: 20251010
...unction startFun() { mFactory = new Templet(); mFactory.on(Event.COMPLETE, this, parseComplete); mFactory.loadAni("res/spine/spineRes2/goblins.sk"); } function parseComplete() { mArmature = mFactory.buildArmature(1); mArmature.x = 100; mArmature.y = 200; var rect=new Laya.Rectangle(-200,-200,300,300...
来源: Laya_社区 发布时间: 20170830
...通过下面的代码,可以初始化A*的地图数据 //读取地形图 this.aStarMap = Loader.getTexture2D("res/threeDimen/scene/TerrainScene/Assets/AStarMap.png"); //获得地图数据 var aStarArr = this.createGridFromAStarMap(this.aStarMap); //使用astar初始化地图数据 this.graph = new...
来源: Laya3.0_文档 发布时间: 20230303
...}); //加载图集资源 Laya.loader.load(asset, laya.utils.Handler.create(this, onLoaded), laya.utils.Handler.create(this, onLoading, null, false)); 嗯 加载改好了 我们先来测试一下 图片是否能拿到 我们在onLoaded方法里面 写一点测试代码 如下 function onLoaded(){ ...
来源: Laya_社区 发布时间: 20160801
....to(letterText, { y : 300 }, 1000, Laya.Ease.bounceIn, Laya.Handler.create(this,this.changeColor,[letterText]), i * 100); 2017-11-22 0 0 分享 微博 QZONE 微信 liner1457387450 赞同来自: 恩恩,你写的这句是基本的用法,我想用tween API里complete()立即完成的方法。...
来源: Laya_社区 发布时间: 20171122
...载进度 Laya.loader.create(res,null,Laya.Handler.create(this,this.onProgress,null,false)); 2020-11-30 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 2 个回复 1605953523用户 赞同来自: 我把资源放...
来源: Laya_社区 发布时间: 20201130