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

大约有 1,282 项符合查询结果, 库内数据总量为 30,724 项。 (搜索耗时: 0.0072 秒)

471. Laya.loader加载BUG [ 70%]

Laya.loader加载BUG 加载图片的时候,源码里这一步会的url为“”的时候,会执行this.onLoaded(null)这一步_ _proto.load=function(url,type,cache,group,ignoreCache,useWorkerLoader){         (cache===void 0)&& (cache=true);         (ignoreCache===void 0)...

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

472. 加载一个txt文件 getRes出来类型为string 能转换成数组吗 [ 70%]

...载一个txt文件 getRes出来类型为string 能转换成数组吗 Laya.loader.load("res/text.txt", Handler.create(this, onAssetLoaded1), null, Loader.TEXT); var pic1 = Loader.getRes("res/2D特效/text.txt"); console.log(typeof pic1); 输出的类型为string 2017-06-20 添加评论 免费帖 --> ...

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

473. UI-Tab [ 70%]

...e = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Stat.show(); Laya.loader.load(skins, Handler.create(this, this.onSkinLoaded)); } onSkinLoaded() { let tabA = this.createTab(skins[0]); tabA.pos(40, 120); tabA.labelColors = "#000000,#d3d3d3,#333333"; let tabB =this. createTab(skins[1]); tabB.p...

来源: Laya2.0_示例 发布时间: 20240930

474. 请问如何释放atlas和他的png资源 [ 70%]

...ction clickFun():void { url = "res/CH/atlas/MORNUI_Z_Gongneng.atlas"; Laya.loader.load(url,new Handler(this,hh)); //trace( Laya.loader.getRes(url) ); } private function hh():void { Laya.stage.addChild(new Image("MORNUI_Z_Gongneng/clip_xue_quan.png")); Laya.timer.once(1000,1,ddd); } private function ...

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

475. 请问我用网络格式加载成功后,在服务器替换image.atlas和images.png重新打开小游戏没有重新加载服务器的png,只重新加载了atlas [ 70%]

...Array = [ //{ url: "https://piggy.com/res/atlas/images.atlas", type : Laya.Loader./png}, { url: "https://piggy.com/res/atlas/images.atlas", type: Laya.Loader.ATLAS }, { url: "https://piggy.com/res/swf/flash.json", type: Laya.Loader.JSON }, { url: "images/background.png", type: Laya.Loader.IMAGE }, {...

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

476. UI-Slider [ 70%]

...ins.push("../../res/ui/vslider.png", "../../res/ui/vslider$bar.png"); Laya.loader.load(skins, Handler.create(this, onLoadComplete)); })(); function onLoadComplete() { placeHSlider(); placeVSlider(); } function placeHSlider() { var hs = new HSlider(); hs.skin = "../../res/ui/hslider.png"; hs.width = ...

来源: Laya_示例 发布时间: 20240930

477. load方法加载cdn上面的图片资源的时候直接报了跨域不同源的问题,怎么破? [ 70%]

... ]; this.isFirst = true; console.log('Gzdaze='); console.log(Gzdaze); Laya.loader.load(Gzdaze.dialogList, Handler.create(this, this.startLoaded)); 代码是这样的 报错 Access to Image at 'http://caifu-1251177394.file.myqcloud.com/beta/book/bookLaya/img/progressBar$bar.png' from origin 'http://b...

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

478. UI-Button [ 70%]

...VERTICAL_SPACING * (skins.length / COLUMNS - 1) - BUTTON_HEIGHT) / 2; Laya.loader.load(skins, Handler.create(this, this.onUIAssetsLoaded)); } onUIAssetsLoaded() { for (let i = 0, len = skins.length; i ; constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(800, 600, WebGL); Laya.stage....

来源: Laya2.0_示例 发布时间: 20240930

479. UI-Button [ 70%]

...VERTICAL_SPACING * (skins.length / COLUMNS - 1) - BUTTON_HEIGHT) / 2; Laya.loader.load(skins, Handler.create(this, onUIAssetsLoaded)); })(); function onUIAssetsLoaded() { for (var i = 0, len = skins.length; i ; constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(800, 600, WebGL); Lay...

来源: Laya_示例 发布时间: 20240930

480. 怎么同步加载资源 [ 70%]

...内容相关的链接 提交 3 个回复 Laya_XS 赞同来自: 你用Laya.loader.load一次加载很多图片,也是在图片加载完毕才返回完成事件的,但是有一种情况也会返回完成,就是你资源加载失败也会忽略,因为我们也不会因为你在队列里存在...

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