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

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

111. 1.6.2打包的图集不能使用 [ 82%]

1.6.2打包的图集不能使用 图集大小只有77K 了, 然后loader.load之后,总是显示longtime  。。在断点的情况下。 Laya.loader.load([{url: "res/atlas/longCard.json", type: Loader.ATLAS}], Handler.create(this, onLoaded)); 在onLoaded var textrue = Laya.loader.getRes(long...

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

112. 材质-BlinnPhong-高光贴图 [ 82%]

..., 1, 1); var completeHandler = Laya.Handler.create(this, onComplete); Laya.loader.create("../../res/threeDimen/skinModel/dude/dude.lh", completeHandler); function onComplete() { var dude1 = this.scene.addChild(Laya.Sprite3D.load("../../res/threeDimen/skinModel/dude/dude.lh")); dude1.transform.positi...

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

113. canvas下资源清理的问题 [ 82%]

...aya.display.Stage;     import laya.events.Event;     import laya.net.Loader;     import laya.ui.Button;     import laya.utils.Handler;     import laya.utils.Stat;          import ui.TaskUI;          import view.TestView;          public class LayaUISample {      ...

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

114. [0]laya-zip游戏加载提速库(Laya3.0版本适配更新) [ 82%]

...res/3d/Player.zip,则使用方法为[code]// Laya 2.x及以下版本 Laya.loader.create([{ url: "res/3d/Player.zip", type: LayaZip.ZIP}])[/code][code]// Laya3.x版本 Laya.loader.load([{ url: "res/3d/Player.zip", type: LayaZip.ZIP}])[/code] 加载资源使用:[code]// Laya 2.x及以下版本 let pla...

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

115. 动画-图集动画 [ 82%]

...tage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Laya.loader.load(aniConfPath, Laya.Handler.create(this, this.createAnimation), null, Laya.Loader.ATLAS); } createAnimation() { const Animation = Laya.Animation; let ani = new Animation(); Laya.stage.addChild(ani); ani.loadAtlas(an...

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

116. Laya.SoundManager.playSound 无法播放出音效 [ 82%]

...不能正常播放,也没有任何错误提示 然后尝试先调用Laya.loader.load("sfx/hit01.mp3",new Laya.Handler(this,this.onBgmComplete),null,Laya.Loader.SOUND);然后在onBgmComplete的回调里面再调用播放,就会提示 [warn]Retry to load: sfx/hit01.mp3 [error]Failed to load: sfx/h...

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

117. 分享:LayaAir下如何获取图集下的小图资源? [ 82%]

...import laya.display.Animation; import laya.display.Sprite; import laya.net.Loader; import laya.resource.Texture; import laya.utils.Handler; public class Main { public function Main() { //初始化引擎 Laya.init(600, 800); //加载引擎需要的资源 Laya.loader.load([{url:"res/atlas/atlas_res.js...

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

118. 是不BMFONT不支持多类型资源加载方式? [ 82%]

...式? var assets = []; assets.push( { url: "res/fontWord.fnt", type: Laya.Loader.FONT }); Laya.loader.load(assets, Laya.Handler.create(this, onAssetsLoaded)); function onAssetsLoaded(){ var bitmapFont = new Laya.BitmapFont(); bitmapFont.loadFont("res/fontWord.fnt"); //必出错 }     只要使用...

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

119. l微信开放域无法显示,但是可以正常传数据 [ 82%]

...main.ts: if(Laya.Browser.onMiniGame){ //加载一个json和图集 Laya.loader.load(["res/atlas/test.atlas"],Laya.Handler.create(null,function(){ //加载完成 //使用接口将图集透传到子域 Laya.MiniAdpter.sendAtlasToOpenDataContext("res/atlas/test.atlas"); }));子域main.ts: import GameC...

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

120. 材质-BlinnPhong-法线贴图 [ 81%]

...ctor3(0, -0.8, -1); directionLight.color = new Laya.Vector3(1, 1, 1); Laya.loader.create("../../res/threeDimen/staticModel/lizardCal/lizardCaclute.lh", Laya.Handler.create(this, onComplete)); function onComplete() { var monster1 = this.scene.addChild(Laya.Sprite3D.load("../../res/threeDimen/staticMo...

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