大约有 132 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0039 秒)
...度的回调。。。 function beginLoad(){ Laya.loader.load("./res/atlas/comp.atlas", Handler.create(null, onLoaded),Laya.Handler.create(this,onProgress,null,false)); } function onProgress(value:any):void{ console.log(value); } jinfawu • 2018-03-21 15:22 @Monica:项目已上传至微云...
来源: Laya_社区 发布时间: 20180321
...方文档是错的,几年了至今无解答 let aniEffConfPath = './res/atlas/comp.atlas' Laya.loader.load(aniEffConfPath, Laya.Handler.create(this, this.onLoaded)) onLoaded(){ // Laya.ClassUtils.regClass('ui.TestPUI', ui.TestPUI) var efc = new ui.TestPUI(); Laya.stage.addChild(efc); } 按照官...
来源: Laya_社区 发布时间: 20210111
...); Stat.show(); //加载引擎需要的资源 Laya.loader.load([{url: "res/atlas/comp.json", type: Loader.ATLAS}], Handler.create(this, onLoaded)); } private function onLoaded():void { //实例UI界面 Laya.stage.bgColor="#353535"; sp1=createSprite(50,50);//创建方块1 sp2=createSprite(250,50);//...
来源: Laya_社区 发布时间: 20161207
...; Laya.stage.alignH = Laya.Stage.ALIGN_CENTER; Laya.loader.load([{url:"res/atlas/comp.json",type:Laya.Loader.ATLAS}],Laya.Handler.create(this,this.loadComp)); } private loadComp():void{ var parent:ui.ParentViewUI = new ui.ParentViewUI(); Laya.stage.addChild(parent); //当注释掉设置rotaion的代...
来源: Laya_社区 发布时间: 20170829
...源,加载成功后将UI界面添加到舞台上 Laya.loader.load("./res/atlas/comp.atlas",Laya.Handler.create(this,onLoaded)); function onLoaded(){ //实例化导出的UI类 var efc = new ui.TestPUI(); //添加到舞台 Laya.stage.addChild(efc); } ``` 运行后,按钮被按下时,动画效果...
来源: Laya2.0_文档 发布时间: 20210715
...样,就是图集的分辨率不对。附件已经给了,请注意res/atlas/comp.png 这张图的分辨率,比正确的图宽和高都多了像素 lookdczar • 2017-12-31 23:21 另外一个人也和我出现了一样的问题 https://ask.layabox.com/question/10105 lookdczar • 2017-12-31 23:3...
来源: Laya_社区 发布时间: 20171230
...载图集资源,加载成功后添加到舞台 Laya.loader.load("./res/atlas/ui.atlas",Handler.create(this,onLoaded)); } private function onLoaded():void { //实例导出的UI类 var efc:EffectAnimationDemoUI = new EffectAnimationDemoUI(); //添加到舞台 Laya.stage.addChild(efc); } } } ``` 运...
来源: Laya2.0_文档 发布时间: 20210715
...#ffcccc"; //加载界面需要的资源文件 Laya.loader.load([{url: "res/atlas/comp.json", type: Loader.ATLAS}], Handler.create(this, onLoaded)); } private function onLoaded():void { //实例UI界面 listP = new ListPageUI(); Laya.stage.addChild(listP); Laya.timer.once(1000,this,onAdd);//1000毫...
来源: Laya_社区 发布时间: 20170313
...dth >> 1, Laya.stage.height >> 1); // 位置 this.clip.skin = "atlas/comp/clip_num.png"; // 皮肤 this.clip.interval = 1000; // 切片动画的播放时间间隔1000毫秒 this.clip.clipX = 10; // 切片x轴数量 this.clip.autoPlay = true; // 动画自动播放 } } 二、通过代码...
来源: Laya3.0_文档 发布时间: 20251010
... onAwake(): void { this.btn.scale(5, 5); //放大五倍 this.btn.skin = "atlas/comp/button.png"; //皮肤 this.btn.stateNum = 3; //皮肤状态 this.btn.label = "确定"; //文本标签 this.btn.labelFont = "宋体"; //文本标签字体 this.btn.labelSize = 20; //文本标签字体大小 this.btn.l...
来源: Laya3.0_文档 发布时间: 20251010