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

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

1. 事件管理 · LayaAir3.3 · 引擎文档 · LAYABOX [ 100%]

...是事件1.2 事件的分类2. 引擎内置的事件2.1 事件类型 Laya.Event2.2 事件派发 Laya.EventDispatcher2.3 事件处理 Laya.Handler3. 自定义的事件事件管理 1. 认识事件 1.1 什么是事件 事件Event指的是由系统事先设定的、能被对象识别和响应的动作...

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

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

...tion; } } /** * 监听鼠标事件 */ onAwake(): void { Laya.stage.on(Laya.Event.MOUSE_DOWN, this, this.mouseDown); Laya.stage.on(Laya.Event.MOUSE_UP, this, this.mouseUp); this.camera = (<Laya.Camera>this.owner); } /** * 监听键盘事件 */ onUpdate(): void { var elapsedTime: number = Laya.t...

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

3. 基础文本 · LayaAir3.3 · 引擎文档 · LAYABOX [ 71%]

...xt.borderColor = "#fa1515"; this.txt.overflow = "scroll"; this.txt.on(Laya.Event.MOUSE_DOWN, this, this.startScrollText); } /* 开始滚动文本 */ startScrollText() { prevX = this.txt.mouseX; prevY = this.txt.mouseY; Laya.stage.on(Laya.Event.MOUSE_MOVE, this, this.scrollText); Laya.stage.on(Laya.E...

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

4. TiledMap地图 · LayaAir3.3 · 引擎文档 · LAYABOX [ 55%]

...ale(0,0); //将原地图放大3倍 this.tMap.scale = 3; Laya.stage.on(Laya.Event.RESIZE,this,this.resize); Laya.stage.on(Laya.Event.MOUSE_DOWN, this, this.mouseDown); Laya.stage.on(Laya.Event.MOUSE_UP, this, this.mouseUp); this.resize(); } //地图加载完成的回调 private completeHandler(e: any...

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

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

... void { this.bar.value = 1; this.value.visible = false; Laya.stage.on(Laya.Event.CLICK, this, this.onHurt); } onHurt(): void { this.bar.value = this.bar.value - 0.9; this.value.y = 35; this.value.visible = true; Main.instance.animator.play("stun"); Laya.Tween.create(this.value).to("y", -30).duration...

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