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

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

131. 类似古文显示方式脚本,文字垂直显示,可以控制显示速度出现打字效果等 [ 55%]

...果等  /**古文脚本 */ export default class TextAncient extends Laya.Script { /** @prop {name:text, tips:"显示文本", type:String, default:"hello world"}*/ public text: string = "hello world"; /** @prop {name:color, tips:"字符串类型示例", type:String, default:"#0000ff"}*/ public color...

来源: Laya_社区 发布时间: 20191103

132. UI弹窗 · LayaAir3.0文档 · LAYABOX [ 55%]

...gClass, property } = Laya; @regClass() export class UI_Dialog extends Laya.Script { private DIALOG_WIDTH: number = 220; private DIALOG_HEIGHT: number = 275; private CLOSE_BTN_WIDTH: number = 43; private CLOSE_BTN_PADDING: number = 5; private assets: any[]; private dialog: Laya.Dialog; constructor() ...

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

133. Dialog 第一次打开总是出现在窗口右下角,这是为啥,再打开就正常剧中了? [ 54%]

...archKey":"Dialog", "props":{"width":1624,"sceneColor":"#000000","runtime":"script/view/dialogs/SettingDialog.js","height":750}, "nodeParent":-1, "maxID":4, "label":"Dialog", "isOpen":true, "isDirectory":true, "isAniNode":true, "hasChild":true, "compId":2, "child":[ { "x":15, "type":"Image", "searchK...

来源: Laya_社区 发布时间: 20200417

134. 动画混合问题,Avatar动画混合报错. [ 54%]

...ad property 'time' of undefined laya.d3.js:22278 at Animator.__proto._eventScript (file:///F:/Program/PF_LAYA2.1/game/bin/libs/laya.d3.js:22278:15)   at Animator.__proto._updateEventScript (file:///F:/Program/PF_LAYA2.1/game/bin/libs/laya.d3.js:22315:11)   at Animator.__proto._update (file:///F:/P...

来源: Laya_社区 发布时间: 20191026

135. HTTP通信 · LayaAir3.4 · 引擎文档 · LAYABOX [ 54%]

...。 二、使用引擎的请求方法 XMLHttpRequest(XHR)是一个 JavaScript 对象,它提供了一种在浏览器中以异步方式发送 HTTP(或 HTTPS)请求并处理服务器响应的机制。例如,获取远程资源、提交表单数据、发送JSON数据等。 在LayaAir引擎中...

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

136. 项目启动入口说明 · LayaAir3.4 · 引擎文档 · LAYABOX [ 53%]

... { regClass, property } = Laya; @regClass() export class Main extends Laya.Script { onStart() { console.log("Game start"); } } 2.2 场景的脚本说明 前面讲了项目的入口, 本小节简述一下场景的脚本。场景的脚本主要是两类, 一类是自定义的组件脚本。这种...

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

137. 2D方向光 · LayaAir3.4 · 引擎文档 · LAYABOX [ 53%]

... const { regClass } = Laya; @regClass() export class DayNight extends Laya.Script { declare owner: Laya.Sprite; private lightComp: Laya.DirectionLight2D; private dayTime: number = 0; private dayDuration: number = 24; // 一个完整周期的秒数 private displayText: Laya.Text; // 文本显示当...

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

138. Laya3D 中如何解决3D模型上添加文本的问题,类似Unity中的3DText [ 53%]

... 大大大懒猫 • 2018-09-10 10:39 export class ShopTitle extends Laya.Script{ public title: string; constructor(){ super(); } public _initialize(owner: Laya.Sprite3D): void { super._initialize(owner); var sprite3D = this.owner as Laya.MeshSprite3D; var sprite3DMat = new Laya.StandardMaterial(); ...

来源: Laya_社区 发布时间: 20180814

139. [LayaAirIDE3]咋么实现鼠标点击角色移动 [ 53%]

...roperty } = Laya; @regClass() export default class iceMonster extends Laya.Script { declare owner: Laya.Sprite; /** 用于兜底的 Animator2D(可选) */ private _animator: Laya.Animator2D; /** 承载 .mc 的动画播放器 */ private iceMonsterAni: Laya.Animation; /** 资源前缀 */ private re...

来源: Laya_社区 发布时间: 20251211

140. 抖音小游戏 · LayaAir3.4 · 引擎文档 · LAYABOX [ 53%]

...例如下: const { regClass, property } = Laya; @regClass() export class Script extends Laya.Script { //declare owner : Laya.Sprite3D; @property({ type: Laya.Scene3D }) scene3d: Laya.Scene3D; constructor() { super(); } /** * 组件被激活后执行,此时所有节点和组件均已创建完毕...

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