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

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

1. UI运行时 · LayaAir3.0文档 · LAYABOX [ 100%]

...脚本,而后添加的代码如下所示: const { regClass } = Laya; import { RuntimeScriptBase } from "./RuntimeScript.generated"; @regClass() export class RuntimeScript extends RuntimeScriptBase { onAwake(): void { // Button添加鼠标事件,让Image不显示 this.Button.on( Laya.Event.MOUS...

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

2. 插件开发说明 · LayaAir3.0文档 · LAYABOX [ 88%]

...p,glob,pinyin, @svgdotjs/svg.js等。引用node内置模块可以使用import xx from "xx"的方式,所有IDE内置cjs模块都可以通过IEditor.require或者IEditorEnv.require去引用。 //可以通过import导入node内置模块 import fs from "fs"; import path from "path"; //也可以通...

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

3. 弹窗视图组件 · LayaAir3.0文档 · LAYABOX [ 58%]

...,在RuntimeScript.ts中添加如下代码: const { regClass } = Laya; import { RuntimeScriptBase } from "./RuntimeScript.generated"; @regClass() export class RuntimeScript extends RuntimeScriptBase { onAwake(): void { this.closeBtn.on(Laya.Event.CLICK, this, () => { this.close(); }); } } 1.3....

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

4. 组件装饰器说明 · LayaAir3.0文档 · LAYABOX [ 38%]

...面这两个TS代码: //MyScript.ts const { regClass, property } = Laya; import Animal from "./Animal"; @regClass() export class MyScript extends Laya.Script { @property({ type : Animal }) animal : Animal; } //Animal.ts const { regClass, property } = Laya; @regClass() export default class Animal {...

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

5. 实体组件系统 · LayaAir3.0文档 · LAYABOX [ 30%]

...面这两个TS代码: //MyScript.ts const { regClass, property } = Laya; import Animal from "./Animal"; @regClass() export class MyScript extends Laya.Script { @property({ type : Animal }) animal : Animal; } //Animal.ts const { regClass, property } = Laya; @regClass() export default class Animal {...

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