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

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

411. 3D场景环境设置 · LayaAir3.3 · 引擎文档 · LAYABOX [ 62%]

...//加载相机天空盒材质 Laya.Material.load("sky2.lmat", Laya.Handler.create(null, function(mat: any) { //修改天空盒渲染器的天空盒材质 skyRenderer.material = mat; })); 2.3 IDE中创建天空盒 2.3.1 更改IDE默认的球形天空盒 当我们用IDE场景一个3D场景时,默认...

来源: Laya3.0_文档 发布时间: 20251010

412. 动画挂点(ActionScript-3D基础(AS3)-LayaAir3D之Animator动画) [ 62%]

...t Scene3D.load("LayaScene_SceneMonkey/Conventional/SceneMonkey.ls",Handler.create(this,function(res:Scene3D):void{ Laya.stage.addChild(res); //用于挂点的精灵 var box: MeshSprite3D = new MeshSprite3D(PrimitiveMesh.createBox(1,1,1)); var material: BlinnPhongMaterial = new BlinnPhongMaterial(); ...

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

413. Image加载完成后的图片大小重设问题 [ 62%]

....loadImage("ui/bg.jpg",0,0,Laya.stage.width,Laya.stage.height,Laya.Handler.create(this,this.onComplete));         Laya.stage.on(Laya.Event.RESIZE,this,this.onResize);     }     onComplete():void     {         this.onResize();     }     onResize():void{         this.bg_img.width...

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

414. 分享:LayaAir下如何加载和使用.JSON文件! [ 62%]

...LayaAirDemo() { Laya.init(500,400); Laya.loader.load("unpack.json",Handler.create(this,onLoaded),null,Loader.JSON); } private function onLoaded():void { var json:JSON=Laya.loader.getRes("unpack.json"); var str:String=JSON.stringify(json); trace(str); } } } 2017-08-07 添加评论 免费帖 --> 分...

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

415. 分享:Dragonbones/Spine的换肤操作 [ 61%]

...n);//添加动画至舞台,这时候运行,动画已经可以播放了 createButton();//创建一个按钮,用来切换皮肤使用 } private function createButton():void { var btn:Sprite=new Sprite();//绘制一个红色矩形按钮 btn.graphics.drawRect(0,0,150,30,'#FF0000'); btn.pos(10,430)...

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

416. Mac下LayaAirIDE1.7.20版本声音预加载失败,但windows下同个版本加载正常 [ 61%]

...ader.SOUND}         ];         Laya.loader.load(assetArr,Handler.create(this,onComplete),Handler.create(this,onProgress)); } private function onProgress(loadNum:Number):void { }   private function onComplete():void { } 附件 : --> 2018-11-12 添加评论 免费帖 --> 分享 微博 QZONE...

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

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

...8 14:32 Laya.loader.load("res/config/preloadAssets.xml", Handler.create(this, this.onPreloadConfigLoaded), null, "xml"); 就一行代码,比如这样的,就是load不下来了,你们小游戏里可以load xml的吗 qian • 2018-02-08 14:42 本地文件必须是ASCII格式 ...

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

418. 如何实现类似AS3下的BitmapData.draw去截取区域图片? [ 61%]

...复 cuixueying 赞同来自: 1、譬如我有一张图片 2、通过TextureCreate创建package {     import laya.display.Sprite;     import laya.resource.Texture;     import laya.utils.Handler;     public class CupPhone     {         public function CupPhone()         {  ...

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

419. 微信小游戏运行导出项目的时候报错:Scene: the .lh file root type must be Scene [ 61%]

...yaAir3D constructer start loadres url:", this._sceneURl); Laya.loader.create([{url:this._sceneURl, clas:MyScene}], Laya.Handler.create(this, this.loadComplete)); } private loadComplete():void { console.log("debuginfo LayaAir3D constructer loadres complete"); this._scene = MyScene.load...

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

420. Laya.URL.basePath加载不到网络资源 [ 61%]

..., type : Laya.Loader.IMAGE}, ];   Laya.loader.load(resArray, Laya.Handler.create(this, this.onLoaded2));   Laya.URL.basePath = "https://piggy.q1.com"; var resArray = [ { url: "res/atlas/images.atlas", type : Laya.Loader.ATLAS}, // { url: "res/swf/flash.json", type: Laya.Loader.JSON}, // { url: "im...

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