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

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

911. 多线程Worker · LayaAir3.3 · 引擎文档 · LAYABOX [ 38%]

...引擎需要的资源 Laya.loader.load("../atlas/comp.atlas",Laya.Handler.create(this,this.onLoaded)); } private onLoaded():void{ //实例UI界面 var testView:ui.test.TestPageUI = new ui.test.TestPageUI(); Laya.stage.addChild(testView); } } new LayaUISample; WorkerLoader.workerPath = "libs/worker.j...

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

912. laya.ui.Button_API3.0 [ 38%]

...布的背景颜色。 Laya.loader.load("resource/ui/button.png", Handler.create(this,onLoadComplete));//加载资源。 } private function onLoadComplete():void { trace("资源加载完成!"); var button:Button = new Button("resource/ui/button.png","label");//创建一个 Button 类的实例对象...

来源: Laya3.0_api 发布时间: 20231115

913. 微信小游戏加载资源问题 [ 38%]

....EventDispatcher { constructor() { super(); this.loaded = false; } static _createSound() { MiniSound._id++; return MiniAdpter.window.wx.createInnerAudioContext(); } load(url) { if (!MiniFileMgr.isLocalNativeFile(url)) { url = Laya.URL.formatURL(url); } else { if (!MiniFileMgr.isWXPath(url)) { if (Mi...

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

914. 对游戏中各种控件字体样式使用“白鹭style”样式表 [ 38%]

...item.size; items.push(item); var progressHandler = progress ? Laya.Handler.create(null, loadProgress, [item], false) : null; var completeHandler = (complete || progress) ? Laya.Handler.create(null, loadComplete, [item]) : null; this.load(item.url, completeHandler, progressHandler, item.type, item.pr...

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

915. 2D性能优化 · LayaAir3.3 · 引擎文档 · LAYABOX [ 37%]

...ew Laya.Sprite(); sp.loadImage("res/apes/monkey2.png",0,0,0,0,Laya.Handler.create(this,function() { console.log(sp.width,sp.height); })); Laya.stage.addChild(sp); loadImage在加载完成的回调函数触发之后才可以正确获取宽高。 直接调用size设置: Laya.loader.load("res/apes/mo...

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

916. [BUG]刚体约束问题,移动后约束混乱! [ 37%]

...r plane = this.scene.addChild(new Laya.MeshSprite3D(Laya.PrimitiveMesh.createPlane(40, 40, 40, 40)));     plane.transform.position = new Laya.Vector3(0, -2.0, 0);     var planeMat = new Laya.BlinnPhongMaterial();     Laya.Texture2D.load("res/threeDimen/Physics/grass.png",...

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

917. UI-RefreshList [ 37%]

... "#232628"; Laya.loader.load("res/ui/refreshList/ani/refresh.png", Handler.create(this, function(){ this.initView(); })); } initView(){ // 加载并添加场景中需要使用的资源 this.baseBox = new Box(); this.baseBox.width = 443; this.baseBox.height = 622; this.baseBox.pos(30, 28); this.baseB...

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

918. [LayaNative3]2d示例程序构建发布打包后,在OpenHarmony运行闪退 [ 37%]

...tegratedHsp... after 1 ms > hvigor Finished :libSysCapabilities:default@CreateHarBuildProfile... after 2 ms > hvigor Finished :libSysCapabilities:default@ConfigureCmake... after 1 ms > hvigor Finished :libSysCapabilities:default@MergeProfile... after 5 ms > hvigor Finished :entry:default...

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

919. [LayaAirIDE3]xcode切入切出声音不播放 [ 37%]

... currentBgmUrl, type: Laya.Loader.SOUND }],             Laya.Handler.create(this, () => {                 console.log("----playMusic111 加载完成------");                  // 关键:添加延迟确保音频会话就绪                 Laya.timer.once(300, this,...

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

920. 多线程worker(JavaScript-2D进阶篇(JS)-游戏加载策略) [ 36%]

...引擎需要的资源 Laya.loader.load("res/atlas/comp.atlas",Laya.Handler.create(this,onLoaded)); function onLoaded(){ //实例UI界面 var testView = ui.test.TestPageUI(); Laya.stage.addChild(testView); } ``` `WorkerLoader.workerPath = "libs/worker.js";`设置worker.js的路径,这个worker.js...

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