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

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

421. 图层叠加的实现 [ 83%]

...叠加的实现 我用 var ape:Sprite = new Sprite(); var t:Texture = Laya.loader.getRes("res/bg.png"); ape.graphics.drawTexture(t,0,0); var t1:Texture = Laya.loader.getRes("res/wzq.png"); ape.graphics.drawTexture(t1,0,0); var t2:Texture = Laya.loader.getRes("res/rkfb.png"); ape.graphics.drawTexture...

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

422. TS分离模式设置未打包图片输出目录导出资源无法加载未打包资源 [ 83%]

...出资源无法加载未打包资源 如图设置 修改加载代码 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

423. 设置遮罩(ActionScript-LayaAir基础篇(AS3)-位图) [ 83%]

...源加载成功后,通过回调方法绘制图片并添加到舞台 Laya.loader.load(Res,Handler.create(this,graphicsImg)); } private function graphicsImg():void { img = new Sprite(); //获取图片资源,绘制到画布 img.graphics.drawTexture(Laya.loader.getRes(Res),150,50); //添加到舞台...

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

424. 关于layaair中类的大小写规则有没有基本的说明文档 [ 83%]

...yaair中类的大小写规则有没有基本的说明文档 比如: Laya.loader.load("res/atlas/comp.json", Laya.Handler.create(null, onLoaded), null, Laya.Loader.ATLAS); Laya.loader.load(resArray, Laya.Handler.create(null,onLoaded)); loader与handler   2017-03-16 添加评论 免费帖 --> 分...

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

425. 照着官方文档写的 Dialog 报错? [ 83%]

...this._container = new Sprite(); Laya.stage.addChild(this._container); Laya.loader.load(["../bin/res/ui/progressBar.png", "../bin/res/ui/progressBar$bar.png"], Handler.create(this, this.onPreloaded)); }; LoadResource.prototype.onPreloaded = function () { this.initLoadData(); }; LoadResource.prototype...

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

426. 使用IDE生成图集后,无论使用图集下的某个小图 [ 83%]

...生成图集后,放到img/assets目录下 然后这样使用:   Laya.loader.load([{ url : 'http://localhost:3000/shoot/v2/img/assets/assets.json', type : Loader.ALTAS }], Handler.create(this, function () { var _getRes = Laya.loader.getRes('bg-toolbar.png'); console.log(_getRes); }));然后log...

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

427. 仅在Android微信小游戏下图片错乱 [ 83%]

...小游戏下图片错乱 static preLoadPublicAssets(){ this.sAssetList = Loader.getRes("file_list.json") Laya.loader.load("res/ui/share@atlas0.png", Handler.create(this, this.onLoaded), null, Loader.IMAGE, 1, true, null, true) } static onLoaded(res){ console.log("public assets inited !!!!") console....

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

428. 如何解析json文件并获取某对象值? [ 82%]

如何解析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

429. 载入场景报错 [ 82%]

...ra 和light,所有代码如下 import Handler=laya.utils.Handler; import Loader=laya.net.Loader; // 程序入口 class GameMain { constructor() { Laya.init(600, 400); Laya.stage.scaleMode = Laya.Stage.SCALE_EXACTFIT; Laya.stage.screenMode = Laya.Stage.SCREEN_VERTICAL; Laya.stage.alignH = Laya.Stag...

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

430. 预加载图集文集在小游戏端导致内存过高 [ 82%]

...y: Array<any> = [ { url: hyip+"res/atlas/comp/01_shouye.json", type: Loader.ATLAS }, { url: hyip+"res/atlas/comp/02_zhujiemian.json", type: Loader.ATLAS }, { url: hyip+"res/atlas/comp/30_loading.json", type: Loader.ATLAS }, ]; Laya.loader.load(resArray, Laya.Handler.create(this, this.onLoaded1...

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