• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 418 项符合查询结果, 库内数据总量为 31,580 项。 (搜索耗时: 0.0042 秒)

141. 预加载结束之后还是报lose skin [ 70%]

...ya.Handler.create(this, this.onAssetLoaded),Laya.Handler.create(this, this.onLoading, null, false)); } private onLoading(progress: number): void { console.log("加载进度: " + progress); } private onAssetLoaded(texture:Laya.Texture){ console.log("加载结束"); } Log输出内容 Warning!,this cla...

来源: Laya_社区 发布时间: 20180314

142. 动画加载成功后设置的描点,在电脑上运行正常,打包APK后到手机上运行,描点未生效 [ 70%]

...if(anin==null)anin=new Animation(); anin.loadAtlas(url,Handler.create(this,onloaded),url); anin.autoSize=true; anin.autoPlay=false; anin.interval=interval;   private function onloaded():void { anin.pivotX=anin.getBounds().width/2; anin.pivotY=anin.getBounds().height/2; }   如上:动画加载成...

来源: Laya_社区 发布时间: 20180806

143. 分享:SWF LABEL标签的使用! [ 70%]

...C"; mc=new MovieClip(); mc.load("output/AAA.swf"); mc.on(Event.LOADED,this,onLoaded); Laya.stage.addChild(mc); } private function onLoaded():void { mc.addLabel("label01",19); mc.addLabel("label02",39); mc.addLabel("label03",59); mc.on(Event.LABEL,this,onLabel);//运行到对应的帧数,会触发...

来源: Laya_社区 发布时间: 20170705

144. 微信小游戏图片加载不出来 [ 70%]

...ader.ATLAS }, ]; Laya.loader.load(resArray, Laya.Handler.create(this, this.onLoaded)); Laya.loader.create("ui/BG/play-bg.png", Laya.Handler.create(this, this.onLoaded)); 在微信小游戏里面可以显示,但是实体机子上就无法显示"ui/BG/play-bg.png"这一张图,其他图片可以 ...

来源: Laya_社区 发布时间: 20181105

145. image.drawToCanvas方法获取的一直是空的png [ 70%]

...e.bgColor = "#232628"; Laya.loader.load("res/logo.png",Handler.create(this,onLoaded)); } private function onLoaded():void { img=new Image(); img.skin="res/logo.png"; Laya.stage.addChild(img); Laya.timer.once(500,this,onClick); //Laya.stage.on(Event.CLICK,this,onClick); } private function onClick():v...

来源: Laya_社区 发布时间: 20170704

146. vivo小游戏 LayaIDE2.2.0使用fairygui报错 [ 70%]

....json", type: Laya.Loader.BUFFER }     ], Laya.Handler.create(this, this.onLoaded)); }  onLoaded(): void {     console.log('===================ss');      console.log('sssss', fgui.GRoot.inst.displayObject);     Laya.stage.addChild(fgui.GRoot.inst.displayObject);       fgui.UIPackage.add...

来源: Laya_社区 发布时间: 20191030

147. ViewStack属性详解(TypeScript-IDE篇(TS)-IDE组件属性详解) [ 70%]

... = "full"; Laya.stage.bgColor = "#ffffff"; //加载图集成功后,执行onLoaded回调方法 Laya.loader.load("res/atlas/comp.atlas",Laya.Handler.create(this,this.onLoaded)); } private onLoaded():void{ //创建一个UI实例 this.comp = new ui.ComponentDemoUI(); //添加到舞台上显示 Laya.st...

来源: Laya2.0_文档 发布时间: 20210715

148. CheckBox属性详解(JavaScript-IDE篇(JS)-IDE组件属性详解) [ 70%]

...heckbox.png"; this.skin2 = "checkbox.png"; //加载资源成功后,执行onLoad回调方法 Laya.loader.load([skin1,skin2],Laya.Handler.create(this,onLoaded)); function onLoaded(){ //创建一个CheckBox实例cb1 var cb1 = new Laya.CheckBox(this.skin1); //添加到舞台上显示 Laya.stage.addChi...

来源: Laya2.0_文档 发布时间: 20210715

149. Laya下的图片上传示例(完整版) [ 70%]

...aURL(file.files[0]); //转换图片格式为字符编码 } } }; fileReader.onload = function(e):void { if(Laya.Browser.window.FileReader.DONE == fileReader.readyState) { var data = e.target.result; img.onload = function(){ var width = img.width; var height = img.height; if(width<100&&heig...

来源: Laya_社区 发布时间: 20190129

150. 1.9LayairIDE创建的微信小游戏示例运行报错 [ 70%]

...t.scriptLoaded (<anonymous>:18:21)     at HTMLScriptElement.script.onload (<anonymous>:30:20) (anonymous) @ code.js? [sm]:1 require @ VM32 WAGame.js:1 (anonymous) @ VM32 WAGame.js:1 (anonymous) @ game.js? [sm]:2 require @ VM32 WAGame.js:1 (anonymous) @ VM118:1 scriptLoaded @ VM41:18 sc...

来源: Laya_社区 发布时间: 20191116