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

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

461. 关于创建Sprite获取大小 [ 61%]

...调。这个是异步获取,如果你要单个获取的话 window.Laya.loader.load(value.url, ls.Handler.create(this, function () { _this.graphics.clear() var texture = window.Laya.loader.getRes(value.url) _this.graphics.drawTexture(texture) _this.scaleX = _this.set_width / texture.sourceWidth _th...

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

462. t._addReference is not a function [ 61%]

... llc 赞同来自: 碰到相同的问题,解决了,供参考: Laya.loader.load(chapterBG, Laya.Handler.create(this, this.onBGLoaded, [chapterBG])/* , Laya.Handler.create(this, this.onBGLoadProgress) */); 第三个参数打开在某些条件下会出t._addReference is not a function 可能是...

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

463. 微信环境下面Laya.Browser.window.protobuf.load不能读取本地的proto文件 [ 60%]

...72:13)     at http://127.0.0.1:53462/game/code.js:97630:17     at Laya.loader.load.Handler.create (http://127.0.0.1:53462/game/code.js:102231:13)     at Handler.__proto.runWith (http://127.0.0.1:53462/game/code.js:711:59)   查看了应该是微信自带的浏览器内核不支持Function.app...

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

464. 关于as版的Animation.createFrames()不能工作? [ 60%]

...ite; import laya.display.Stage; import laya.utils.Handler; import laya.net.Loader; import laya.events.Event; public class LayaUISample { protected var text:Text; protected var aaa:AAA; public function LayaUISample() { Laya.init(1540, 990); Laya.Stat.show(); Laya.loader.load("res/atlas/war.json", Lay...

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

465. layaAir IDE UI导出显示异常 [ 60%]

...后缀格式造成的,而默认例子里面加载的是json格式的: Laya.loader.load("res/atlas/comp.json", Handler.create(this, onAssetLoaded), null, Loader.ATLAS);   所有导致了图集位置错乱,麻烦技术修下这个bug. 建议ui编辑器默认就导出成json格式大图~~   2017-11-1...

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

466. 输入设备-指南针 [ 60%]

...tage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Laya.loader.load(compassImgPath, Handler.create(this, this.init)); } init() { const Gyroscope = Laya.Gyroscope, Event = Laya.Event; // 创建罗盘 this.createCompass(); // 创建方位指示器 this.createDirectionIndicator(); //...

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

467. 有偿解答 Laya致命问题 -预加载,进度问题 [ 60%]

... Laya致命问题 -预加载,进度问题 使用情况描述: 使用Laya.loader.load加载2d和声音资源使用 Laya.loader.create加载3D场景和模型资源 问题描述: 预加载效果不明显(每次进入时,加载进度都非常慢,需要花半分钟加载,20mb的资源)加载模型...

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

468. 生成的粒子特效怎么设置colorComponentInter无效? [ 60%]

...uper(this); letter = letter; this.loadImage('res/jiezou/wenzi2.png'); Laya.loader.load("res/parts/qipao.part", Handler.create(this, onAssetsLoaded), null, Loader.JSON); } function onAssetsLoaded(settings) { settings.colorComponentInter = true; sp = new Particle2D(settings); sp.emitter.start(); sp.pl...

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

469. 求教 JS项目的Promise如何使用 [ 60%]

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

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

470. 按照打地鼠教程来无法正常加载资源 [ 60%]

...as/ui.atlas"},                 {res:"res/ui/back.png",type:Loader.IMAGE}             ];             Laya.loader.load(resArr,Handler.create(this,this.onLoaded));         }         private function onLoaded():void{             //显...

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