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

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

251. 请问一下,怎么将下面这段AS3代码翻译成LayaAir的API [ 72%]

...ar sprite_:Sprite = new Sprite(); var bitmap_:BitmapData = new BitmapData(_loader.width, _loader.height); bitmap_.draw(_loader, new Matrix()); var matrix:Matrix = new Matrix(); matrix.rotate(Math.PI/4); sprite_.graphics.beginBitmapFill(bitmap_, matrix, true); sprite_.graphics.drawRect(100, 50, 200, ...

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

252. 微信小游戏默认项目代码添加unity导出.lh文件,微信开发工具提示错误 [ 72%]

...s/layabox.png"); box.meshRender.material = material; //加载3D资源 Laya.loader.create(["res/LayaScene_girl/girl.lh"],Laya.Handler.create(this,this.on3DComplete)); } /*加载3D资源完成回调*/ private on3DComplete():void{ //创建3D角色 //实例化角色 this.role = Laya.loader.getRes("res/L...

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

253. ls场景文件通过Laya.loader.create()预加载后stage.destroyChildren()出现异常Cannot read property 'visible' of null [ 72%]

ls场景文件通过Laya.loader.create()预加载后stage.destroyChildren()出现异常Cannot read property 'visible' of null   附Demo。   想做不同场景之间的切换。 spriteBtn.on(Laya.Event.CLICK, this, function (e) { Laya.stage.destroyChildren(); newScene(); });问题:LayaAirUnityP...

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

254. 射线检测-射线检测 [ 72%]

...sform.translate(new Laya.Vector3(0, 1, 3)); camera.clearColor = null; Laya.loader.create(["../../res/threeDimen/skinModel/NvWu/NvWu-shenminvwu.lm", "../../res/threeDimen/skinModel/CunMinNan/CunMinNan-cunminnan.lm", "../../res/threeDimen/skinModel/XiaoFeiLong/XiaoFeiLong-xiaofeilong.lm", "../../res/t...

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

255. 隐藏默认的虚拟键、屏蔽APP窗口弹出脚本错误信息 的问题 [ 72%]

...nction LoadRes() { var resArray = [ {url: "res/atlas/comp.json",type: Laya.Loader.ATLAS}, {url: "res/atlas/newhfh.json",type: Laya.Loader.ATLAS}, {url: "res/atlas/newhfh2.json",type: Laya.Loader.ATLAS}, ]; Laya.loader.load(resArray, Laya.Handler.create(null, LoadResComplete)) } function LoadResCompl...

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

256. 已经进行微信适配,微信小游戏loader加载xml失败,其他类型加载成功,这个要怎么解决? [ 72%]

已经进行微信适配,微信小游戏loader加载xml失败,其他类型加载成功,这个要怎么解决? 2018-02-08 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 3 个回复 qian 赞同来自: 不好意思我...

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

257. TimeLineUI不存在的问题 [ 72%]

...gba(0,0,0,0.1)"; //加载图集成功后,执行onLoaded回调方法 Laya.loader.load("res/atlas/apes.atlas", Laya.Handler.create(this, onLoaded)); function onLoaded() { //创建一个UI实例 var plan = new ui.TimeLineUI(); //添加到舞台 Laya.stage.addChild(plan); //播放UI场景中的动画 ...

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

258. 分享-js资源进度加载 [ 72%]

...gress: Progress; Socket: Socket; arr = [ { url: "images/1.jpg", type: Laya.Loader.IMAGE } , { url: "images/2.jpg", type: Laya.Loader.IMAGE } , { url: "images/3.jpg", type: Laya.Loader.IMAGE } , { url: "images/4.png", type: Laya.Loader.IMAGE } , { url: "images/5.jpg", type: Laya.Loader.IMAGE } , { ur...

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

259. 打包之后TEXT可以显示但是 加载其他资源时白屏 [ 72%]

...";  var asset = []; asset.push({ url: ["../res/image/bg.png"], type: Laya.Loader.IMAGE }); Laya.loader.load(asset,Laya.Handler.create(this,graphicsImg)); function graphicsImg(){ var s = new laya.display.Sprite(); s.graphics.drawTexture(Laya.loader.getRes("../res/image/bg.png"),0,0);  Laya.stage.ad...

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

260. Sprite3D-Sprite3D变换 [ 72%]

...); camera.transform.rotate(new Laya.Vector3(-15, 0, 0), true, false); Laya.loader.create("../../res/threeDimen/skinModel/LayaMonkey/LayaMonkey.lh", Laya.Handler.create(this, onComplete)); function onComplete() { layaMonkey1 = scene.addChild(Laya.Sprite3D.load("../../res/threeDimen/skinModel/LayaMonk...

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