大约有 2,661 项符合查询结果, 库内数据总量为 31,625 项。 (搜索耗时: 0.0083 秒)
Laya_社区(2342) Laya2.0_文档(106) Laya3.0_文档(59) Laya_示例(52) Laya3.0_api(51) Laya2.0_示例(43) laya_api(4) Laya2.0_api(4)
...tage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Laya.loader.load(apePath, Laya.Handler.create(this, this.setup)); } setup() { this.createApe(); this.applayFilter(); } createApe() { const Sprite = Laya.Sprite; this.ape = new Sprite(); Laya.stage.addChild(this.ape); let texture =...
来源: Laya2.0_示例 发布时间: 20251219
hBox使用问题 Laya.loader.load(picAy,Handler.create(this, onAssetLoaded)) private function onAssetLoaded():void { for(var i:int=0;i<picAy.length;i++) { var texture:Texture= Loader.getRes(picAy); var ape:Sprite = new Sprite; //ape.x=i*(stageWidth/4) //Tween.to(ape, { x : i*(stageWidth/4) },150...
来源: Laya_社区 发布时间: 20161026
...ER; Laya.stage.scaleMode = "showall"; Laya.stage.bgColor = "#232628"; Laya.loader.load(ApePath, Handler.create(this, setup)); })(); function setup() { normalizeApe(); makeRedApe(); grayingApe(); } function normalizeApe() { var originalApe = createApe(); apeTexture = Laya.loader.getRes(ApePath); orig...
来源: Laya_示例 发布时间: 20251219
...源释放问题 项目中的音乐资源,我在进入项目时使用 Laya.loader.load("allResources/backmusic.mp3", null, null, Loader.SOUND)进行预加载 在退出项目时使用 SoundManager.destroysound("allResources/backmusic.mp3"); Laya.loader.clearRes("allResources/backmusic.mp3",true);释...
来源: Laya_社区 发布时间: 20171010
...ya.core.js:681) at ResInfo.__proto.event (laya.core.js:460) at LoaderManager.__proto._endLoad (laya.core.js:11993) at Loader.onLoaded (laya.core.js:11972) at EventHandler.__proto.runWith (laya.core.js:681) at Loader.__proto.event (laya.core.js:460) at Loader.__pro...
来源: Laya_社区 发布时间: 20170621
...在代码中加载分包,是可以加载到分包内的资源的: Laya.loader.load("sub1/Cube.lh").then((res: Laya.PrefabImpl) => { // ...... }); Laya.loader.load("sub2/Sphere.lh").then((res: Laya.PrefabImpl) => { // ...... }); 4.2 特殊情况下多级目录的分包 有时开发者的分...
来源: Laya3.0_文档 发布时间: 20251010
...tage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Laya.loader.load(apePath, Laya.Handler.create(this, this.setup)); } setup() { this.normalizeApe(); this.makeRedApe(); this.grayingApe(); } normalizeApe() { let originalApe = this.createApe(); originalApe.x = (Laya.stage.width - ap...
来源: Laya2.0_示例 发布时间: 20251219
...s/layabox.png"); box.meshRender.material = material; //加载3D资源 Laya.loader.create(["res/LayaScene_girl/girl.lh"],Laya.Handler.create(this,this.on3DComplete)); } /*加载3D资源完成回调*/ private on3DComplete():void{ //创建3D角色 //实例化角色 this.role = Laya.loader.getRes("res/L...
来源: Laya_社区 发布时间: 20180307
...的地方,只能在每次创建的时候加载字体! 可以通过Laya.loader.load来加载字体,但是这样会造成回调或者promise,使得整个程序都陷在异步里 可以在初始场景加载各种资源,但是问题是我要单独测试某个场景的时候,加载字体就...
来源: Laya_社区 发布时间: 20250910
... 柠檬_酸 赞同来自: 今天也遇到了哈,new Texture就行,Laya.loader.load试了还是 不行 var Texture1= new Laya.Texture(); Texture1.load("res/1.png",Laya.Handler.create(this,function(){ this.sprite.graphics.drawTexture(Texture1,0,0,50,50,null,1,"#FFFFF"); })); 2021-09-17 ...
来源: Laya_社区 发布时间: 20190508