大约有 358 项符合查询结果, 库内数据总量为 31,671 项。 (搜索耗时: 0.0061 秒)
Laya_社区(288) Laya2.0_文档(35) Laya3.0_文档(20) Laya2.0_示例(4) Laya_示例(4) Laya3.0_api(3) laya_api(2) Laya2.0_api(2)
... this.init(); } init():void{ Laya.init(800, 700, Laya.WebGL); Laya.loader.load("res/atlas/images.atlas",Laya.Handler.create(this,this.onLoaded),null,Laya.Loader.ATLAS); } onLoaded(){ console.info("onLoaded"); this.tiledMap = new Laya.TiledMap(); this.tiledMap.createMap("desert.js...
来源: Laya_社区 发布时间: 20171125
...; //设置背景颜色 Laya.stage.bgColor = "#ffcccc"; //加载资源 Laya.loader.load("res/atlas/comp.atlas",Laya.Handler.create(this,onLoaded),null,Laya.Loader.ATLAS) })(); function onLoaded(){ //实例化 var tempBG=new background(); Laya.stage.addChild(tempBG); } })();在background.js里是这...
来源: Laya_社区 发布时间: 20180129
...; //设置stage颜色s Laya.stage.bgColor = "#ffffff"; //加载资源 Laya.loader.load("res/atlas/comp.json",Laya.Handler.create(this,onLoaded),null,Laya.Loader.ATLAS) })(); function onLoaded(){ var _start = new start(); Laya.stage.addChild(_start); } })(); var start = (function(_super){ function st...
来源: Laya_社区 发布时间: 20181220
...击事件啊?而且tab标签点击后没有一直处于按下状态 var Loader = laya.net.Loader; var UI; Laya.init(600, 400); Laya.loader.load("res/atlas/template/Tab栏.json", Laya.Handler.create(this, onAssetLoaded2), null, Loader.ATLAS); function onAssetLoaded2() { Laya.class(MyBoot, "My...
来源: Laya_社区 发布时间: 20160722
...报错 IDE版本 1.7.16beta 项目导出成微信小游戏后,调用Laya.loader.clearRes(url)报错 然后整个游戏卡死 url=res/atlas/Mission.atlas Laya.loader.clearRes(url); (在调用这个方法前图集已加载完成) 附件 : --> 2018-08-15 添加评论 免费帖 --> 分享 微博 ...
来源: Laya_社区 发布时间: 20180815
...中: //加载图集 asset.push( { url: NVHAIDAOMAO_JSON_URL, type: Laya.Loader.ATLAS }, { url: WAR_JSON_URL, type: Laya.Loader.ATLAS } ); Laya.loader.load(asset, laya.utils.Handler.create(this, onLoaded), laya.utils.Handler.create(this, onLoading, null, false)); // 使用图集 var arr = []; for(v...
来源: Laya_社区 发布时间: 20170326
...e === Keyboard.H) { sp.visible = false; //隐藏界面,清理资源 Laya.loader.clearTextureRes("res/bg.jpg"); Laya.loader.clearTextureRes("res/fighter.atlas"); } else if (e.keyCode === Keyboard.S) { //显示界面,资源会自动恢复 sp.visible = true; } } } } ``` **clearTextureRes** 销毁Te...
来源: Laya2.0_文档 发布时间: 20210714
...e === Keyboard.H) { sp.visible = false; //隐藏界面,清理资源 Laya.loader.clearTextureRes("res/bg.jpg"); Laya.loader.clearTextureRes("res/fighter.atlas"); } else if (e.keyCode === Keyboard.S) { //显示界面,资源会自动恢复 sp.visible = true; } } } } ``` **clearTextureRes** 销毁Te...
来源: Laya2.0_文档 发布时间: 20200929
...Laya.Stage.ALIGN_MIDDLE; Laya.stage.alignV = Laya.Stage.ALIGN_CENTER; Laya.loader.load([{ url: "res/atlas/comp.json", type: Loader.ATLAS }], Handler.create(this, this.onLoaded)); function onLoaded(): void { Laya.loader.load("res/comp/dian.part", Handler.create(this, this.onPartLoaded)); } fun...
来源: Laya_社区 发布时间: 20170803
...r引擎 子容器的事件问题 // 程序入口 Laya.init(800, 800); Laya.loader.load([{ url: "res/atlas/comp.json", type: Loader.ATLAS }], Handler.create(this, this.onLoaded)); function onLoaded(): void { //实例UI界面 var testUI: TestUI = new TestUI(); Laya.stage.addChild(testUI); let vhvt: Vi...
来源: Laya_社区 发布时间: 20170822