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

大约有 6 项符合查询结果, 库内数据总量为 30,897 项。 (搜索耗时: 0.0030 秒)

1. 原生平台通信 · LayaAir3.3 · 引擎文档 · LAYABOX [ 100%]

.../** * 同步事件 * @param eventName 事件名称 * @param data 数据 */ static handleSyncMessage(eventName: string, data: string): string { if (eventName == "syncMessage") { return "sync message from platform"; } return "default sync result"; } /** * 异步事件 * @param eventName 事件名称 *...

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

2. 列表组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 81%]

...log("当前选择的索引:" + index); } } class Item extends Laya.Box { static WID: number = 373; static HEI: number = 85; private img: Laya.Image; constructor() { super(); this.size(Item.WID, Item.HEI); this.img = new Laya.Image(); this.addChild(this.img); } setImg(src: string): void { this.img....

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

3. 获取位置信息 · LayaAir3.3 · 引擎文档 · LAYABOX [ 74%]

...ENIED、Geolocation.POSITION_UNAVAILABLE和Geolocation.TIMEOUT之一。 */ static getCurrentPosition(onSuccess: Handler, onError: Handler = null): void { Geolocation.navigator.geolocation.getCurrentPosition(function (pos: any): void { Geolocation.position.setPosition(pos); onSuccess.runWith(Geolocat...

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

4. 使用3D精灵 · LayaAir3.3 · 引擎文档 · LAYABOX [ 67%]

...Sprite3D都有静态或者动态的两种状态,当一个物体标记为static后,就确保这个物体在游戏场景中为静态的、不会移动的物体,进而在游戏的运行过程中让游戏有更加流畅的运行体验。一般而言,在场景中完全静止的物体标记成stat...

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

5. 3D粒子 · LayaAir3.3 · 引擎文档 · LAYABOX [ 55%]

...子特效的路径,创建一个粒子特效,从对象池里拿一个 static Create(path: string): Particle3D { var ret:Particle3D = Pool.getInstance().getItemByClass("Particle3D@" + path, Particle3D); ret.Init(path); return ret; } //粒子特效初始化 private Init(file_path:string): void { if...

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

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

...子特效的路径,创建一个粒子特效,从对象池里拿一个 static Create(path: string): Particle3D { var ret:Particle3D = Pool.getInstance().getItemByClass("Particle3D@" + path, Particle3D); ret.Init(path); return ret; } //粒子特效初始化 private Init(file_path:string): void { if...

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