大约有 418 项符合查询结果, 库内数据总量为 31,580 项。 (搜索耗时: 0.0040 秒)
...(urls, Handler.create(this, this.onAssetLoaded), Handler.create(this, this.onLoading, null, false), Loader.TEXT); // 侦听加载失败 Laya.loader.on(Event.ERROR, this, this.onError); } onAssetLoaded(texture) { // 使用texture console.log("加载结束"); } // 加载进度侦听器 onLoading(progr...
来源: Laya2.0_示例 发布时间: 20251209
...o.parseImgForBuffer = function(url,data){ var _this = this; var image; var onload = function () { // image.onload = null; // image.onerror = null; // var data = Laya.Texture2D._parse(image); // data._url = "sdfasf" // _this.onLoaded(data); img=HTMLImage.create(image.width,image.height,1); img.loadIm...
来源: Laya_社区 发布时间: 20210809
...his.roleAni.loadAtlas("res/atlas/role.atlas",Laya.Handler.create(this,this.onLoaded)); } private onLoaded():void{ //添加到舞台 Laya.stage.addChild(this.roleAni); } } new AtlasAniDemo(); ``` 运行代码,如图5所示。动画已加载到舞台上,默认是未播放状态的。 ); } private onLoaded():void { this.createView(Laya.loader.getRes("view/MyView.json")); } } 因为加载是异步的,很有可能在加载过程中,用户或者其他行为逻辑已经反复开关这个界面多...
来源: Laya_社区 发布时间: 20180113
...eAni = new Animation(); Laya.loader.load(AniConfPath, Handler.create(this, onLoaded), null, Loader.ATLAS); } private function onLoaded(_e:*=null):void { Animation.createFrames(aniUrls("die",6),"dizziness"); roleAni.play(0,true,"dizziness"); Laya.stage.addChild(roleAni); } /** * 创建一组动画的...
来源: Laya2.0_文档 发布时间: 20210715
加载成功要怎样判断呢? 不管是Laya.loader.load(url, onLoaded, ...) 还是Laya.loader.on(Event.COMPLETE, this, onLoaded); 加载失败都会到onLoaded,那怎么区分是不是加载成功? 2017-03-25 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果...
来源: Laya_社区 发布时间: 20170325
.../background.png", "res/m_background.png"], laya.utils.Handler.create(this, onLoaded), laya.utils.Handler.create(this, onLoading, null, false)); //加载进度 function onLoading(progress){ console.log("onLoading: " + progress); } //加载完毕 function onLoaded(){ console.log("onLoaded"); } 我们...
来源: Laya_社区 发布时间: 20160722
...应? var dialog:Image = new Image(picAy[i]); dialog.on(Event.LOADED,this,onLoaded) private function onLoaded(e:*=null):void{ trace(2) } 这代码有什么问题?不调度onLoaded函数,图片显示正常 2016-10-27 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 ...
来源: Laya_社区 发布时间: 20161027
...loader.load([{url: "comp.json", type: Loader.ATLAS}], Handler.create(this, onLoaded)); function onLoaded(){ var aa = new Sprite(); Laya.stage.addChild(aa); var texture = new Laya.Texture(); texture.load('comp/zzw.png' ); setTimeout( function(){ aa.graphics....
来源: Laya_社区 发布时间: 20171226
...url: "res/atlas/longCard.json", type: Loader.ATLAS}], Handler.create(this, onLoaded)); 在onLoaded var textrue = Laya.loader.getRes(longcard/xxx.png)总是undedined。。。求解。。。 相关链接 : http://ask.layabox.com/question/486 图集打包出来没有prefix。。。get了 2017-03...
来源: Laya_社区 发布时间: 20170306