大约有 358 项符合查询结果, 库内数据总量为 31,671 项。 (搜索耗时: 0.0045 秒)
Laya_社区(288) Laya2.0_文档(35) Laya3.0_文档(20) Laya2.0_示例(4) Laya_示例(4) Laya3.0_api(3) laya_api(2) Laya2.0_api(2)
...下: var resources = [ { url: "res/atlas/images/guide.atlas", type: Laya.Loader.ATLAS }, { url: "config/data.txt", type: Laya.Loader.BUFFER }]; Laya.loader.load(resources, Handler.create(this, this.onComplete), Handler.create(this, this.onProcess), null, 1, false); } onComplete(e,a,b) { console.lo...
来源: Laya_社区 发布时间: 20180816
...tElement.clientWidth * 2, document.documentElement.clientHeight * 2); Laya.loader.load('./card/atlas/card.atlas', Laya.Handler.create(this, onLoaded)); function onLoaded() { //创建一个Animation实例 var tl = new Laya.Animation(); //加载动画文件 tl.loadAnimation("./card/card.ani"); //添...
来源: Laya_社区 发布时间: 20180817
...3-30 10:47 你预加载资源怎么写的 yaorao • 2018-03-30 11:29 Laya.loader.load([ { url: "res/common@atlas0.png", type: Loader.IMAGE }, { url: "res/common.fui", type: Loader.BUFFER }, { url: "res/game@atlas0.png", type: Loader.IMAGE }, { url: "res/game.fui&q...
来源: Laya_社区 发布时间: 20180330
...出资源无法加载未打包资源 如图设置 修改加载代码 Laya.loader.load([ { url: "res/atlas/comp.atlas", type: Loader.ATLAS }, { url: "unpack/comp/image.png", type: Loader.IMAGE }, { url: "test/TestPage.json", type: Loader.JSON }, ], Handler.create(this, this.on...
来源: Laya_社区 发布时间: 20171230
怎么在api中找到 Laya.loader.load Laya.loader.load("res/atlas/war.json",Laya.Handler.create(this,this.onloaded),null,Laya.Loader.ATLAS); 这一句,我想找一下Laya.loader.load的使用说明和使用例子,但是不知道怎么找。在api里我开了Laya。 http://layaair.ldc.layabox.c...
来源: Laya_社区 发布时间: 20171017
如何解析json文件并获取某对象值? private jsonParse() { Laya.loader.load("res/atlas/resTest0.json", Handler.create(this, this.onLoaded), null, Loader.JSON); } private onLoaded() { var json : JSON = Laya.Loader.getRes("res/atlas/resTest0.json"); var jsTx = JSON.stringify(json); } 已经...
来源: Laya_社区 发布时间: 20171016
...、TypeScript三种开发语言、LayaAirIDE让项目开发更高效。var Loader = Laya.Loader; var Handler = Laya.Handler; var Event = Laya.Event; // 创建TestPageUI的子类 function TestUI() { TestUI.super(this); //btn是编辑器界面设定的,代码里面能直接使用,并且有代码...
来源: Laya_示例 发布时间: 20260106
...、TypeScript三种开发语言、LayaAirIDE让项目开发更高效。var Loader = Laya.Loader; var Handler = Laya.Handler; var Event = Laya.Event; // 创建TestPageUI的子类 function TestUI() { TestUI.super(this); //btn是编辑器界面设定的,代码里面能直接使用,并且有代码...
来源: Laya2.0_示例 发布时间: 20200319
...tage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Laya.loader.load(aniConfPath, Laya.Handler.create(this, this.createAnimation), null, Laya.Loader.ATLAS); } createAnimation() { const Animation = Laya.Animation; let ani = new Animation(); Laya.stage.addChild(ani); ani.loadAtlas(an...
来源: Laya2.0_示例 发布时间: 20260106
...on.loadAtlas接口的第三个参数来缓存的,如果缓存后用 Laya.loader.clearRes(url,true)这样卸载资源,再次缓存同名动画,播放动画就会闪烁。如果用Laya.loader.clearRes(url,false)卸载,播放动画就不会显示,除非缓存之前先Laya.Animation.clearCache...
来源: Laya_社区 发布时间: 20161128