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

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

1. 二次开发 · LayaAir3.3 · 引擎文档 · LAYABOX [ 100%]

...dge.call("testBool:",false)); obj.value = "Hello OC!"; bridge.callWithBack(function(value: any) { var obj = JSON.parse(value) alert(obj.value); },"testAsyncCallback:", JSON.stringify(obj)); } else if (os == "Conch-android") { alert(bridge.call("testString","hello")); alert(bridge.call("testNumber",2...

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

2. Steam扩展实例 · LayaAir3.3 · 引擎文档 · LAYABOX [ 85%]

...p) { ... // 注册Steam初始化函数 jsvm_value fnInitSteam; jsvm_create_function(env, "initializeSteam", SIZE_MAX, jsInitializeSteam, nullptr, &fnInitSteam); jsvm_set_named_property(env, exp, "initializeSteam", fnInitSteam); } } 2.2 生成动态链接库 生成动态链接库与其使用的...

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

3. 原生语言与JS通信 · LayaAir3.3 · 引擎文档 · LAYABOX [ 84%]

...(ret); conch.postAsyncMessage("asyncMessage", "asyncMessage from js").then(function (data) { alert(data); }) 1.2 在原生端中主动执行JS端脚本 iOS/OC执行JS脚本: [[conchRuntime GetIOSConchRuntime] runJS:@"alert('hello')"]; Android/Java执行JS脚本: ConchJNI.RunJS("alert('hello worl...

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

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

...te(); 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/monkey2.png",L...

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

5. 开放数据域组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 53%]

...ge方法中执行getFriendCloudStorage方法,修改后的方法如下: function init() { wx.onMessage((data) => { console.log("onMessage", data); if (data.type === "updateViewPort") { Layout.updateViewPort(data.box); draw(POWERRANK); } else if (data.type === 'close') { Layout.clear(); } /** *...

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

6. 网络通信 · LayaAir3文档 · LAYABOX [ 48%]

...会打扰到用户。 1,属性 属性 类型 描述 onreadystatechange function 一个JavaScript函数对象,当readyState属性改变时会调用它。 readyState unsigned short 请求的五种状态 response varies 响应实体的类型由 responseType 来指定, 可以是 ArrayBuffer ,Blo...

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

7. 3D粒子 · LayaAir3.3 · 引擎文档 · LAYABOX [ 39%]

...ath = ""; } Pool.getInstance().ClearGroup("Particle3D@" + root_path, this, function(particle_3d:Particle3D) { particle_3d.Clean(); }); } } 5.2 自定义对象池类 export class Pool { private _poolDic:{[key: string]: any;} = {}; private InPoolSign: string = "__InPool"; constructor() { } private sta...

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

8. 3D粒子编辑模块 · LayaAir3文档 · LAYABOX [ 39%]

...ath = ""; } Pool.getInstance().ClearGroup("Particle3D@" + root_path, this, function(particle_3d:Particle3D) { particle_3d.Clean(); }); } } 5.2 自定义对象池类 export class Pool { private _poolDic:{[key: string]: any;} = {}; private InPoolSign: string = "__InPool"; constructor() { } private sta...

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

9. 插件开发说明 · LayaAir3.3 · 引擎文档 · LAYABOX [ 28%]

...求,例如: let str = await Editor.scene.runScript("window.eval", ` (function() { //do something return "hello"; }()) `); 4、场景进程向UI进程发送消息: //选中项目资源面板一个资源 EditorEnv.postMessageToPanel("ProjectPanel", "select", assetId); //调用自定义的Panel...

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