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

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

11. 弹窗视图组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 57%]

...st { 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.3 关联场景 设置好弹窗之后,需要用...

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

12. 基础使用与构成 · LayaAir3.3 · 引擎文档 · LAYABOX [ 57%]

...的格式。 示例代码如下: import { ItemBoxBase } from "./ItemBox.generated"; const { regClass, property } = Laya; @regClass() export class Script extends ItemBoxBase { constructor() { super(); } get dataSource(): any { return super.dataSource; } set dataSource(value: any) { super.dataSource...

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

13. 模型与动画的导入使用 · LayaAir3.3 · 引擎文档 · LAYABOX [ 57%]

...并用鼠标点击屏幕来切换动画 import { MainBase } from "./Main.generated"; import KeyBoardManager = Laya.InputManager; import Keyboard = Laya.Keyboard; const { regClass, property } = Laya; @regClass() export class Main extends MainBase { private _animator: Laya.Animator; private _isRun: bo...

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

14. 使用3D UI · LayaAir3.3 · 引擎文档 · LAYABOX [ 48%]

...下: const { regClass } = Laya; import { BloodBarBase } from "./BloodBar.generated"; import { Main } from "./Main"; @regClass() export class BloodBar extends BloodBarBase { onAwake(): void { this.bar.value = 1; this.value.visible = false; Laya.stage.on(Laya.Event.CLICK, this, this.onHurt); } onHur...

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

15. 场景管理 · LayaAir3.3 · 引擎文档 · LAYABOX [ 44%]

...下所示: const { regClass } = Laya; import { MsgRTBase } from "./MsgRT.generated"; @regClass() export class MsgRT extends MsgRTBase { onOpened(param: any): void { console.log(param.text); } } 这样,点击Scene场景中的Button,就会打印日志“点击成功!”,效果如动图2-3所...

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

16. 预制体模块 · LayaAir3文档 · LAYABOX [ 36%]

...组预制体的实现代码: import { LoadingRTBase } from "./LoadingRT.generated"; const { regClass, property } = Laya; @regClass() export default class LoadingRT extends LoadingRTBase { onAwake(): void { Laya.loader.load( //先加载本场景要用的 ["resources/UI/image.png", "resources/UI/pro...

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

17. 预制体 · LayaAir3.3 · 引擎文档 · LAYABOX [ 36%]

...组预制体的实现代码: import { LoadingRTBase } from "./LoadingRT.generated"; const { regClass, property } = Laya; @regClass() export default class LoadingRT extends LoadingRTBase { onAwake(): void { Laya.loader.load( //先加载本场景要用的 ["resources/UI/image.png", "resources/UI/pro...

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

18. 屏幕适配 · LayaAir3.3 · 引擎文档 · LAYABOX [ 30%]

...t来设置。 示例代码如下: import { IndexRTBase } from "./IndexRT.generated"; const { regClass } = Laya; @regClass() export default class IndexRT extends IndexRTBase { onAwake(): void { //设置舞台设计宽高 Laya.stage.designWidth = 1080; Laya.stage.designHeight = 1920; //在引擎初...

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

19. Unity资源导出插件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 29%]

...持情况如下: Unity的纹理属性 LayaAir是否支持导出的说明 Generate Mip Maps(生成Mipmap) 部分支持(仅支持是否勾选的状态) Wrap Mode(循环模式) 部分支持(包括:Repeat重复、Clamp强制拉伸) Filter Mode(过滤模式) 支持(包括:Poin...

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

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

...export class DemoThumbnailPlugin extends IEditorEnv.AssetThumbnail { async generate(asset: IEditorEnv.IAssetInfo): Promise<string | Buffer> { //这里可以返回两种类型 //1. 字符串类型。为一个png/jpg/svg文件的绝对路径。 //2. Buffer类型。为一个png/jpg/svg格式的...

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