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

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

421. [LayaAirIDE3]3.3 新版ui 元素处于滚动区域内,localToGlobal坐标转换异常,没有加上滚动值 [ 52%]

...转换时不要使用parent去做转换,把代码下面这样也行: const pos = (this.owner as Laya.Sprite).localToGlobal(new Laya.Point(0, 0)); 2025-08-15 1 1 分享 微博 QZONE 微信 Recovery 赞同来自: ??? 2025-08-12 0 2 分享 微博 QZONE 微信 为什么被折叠? 0 个回复...

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

422. laya.maths.Point [ 52%]

... All Classes | Index | Frames No Frames PointProperties | Methods | Constants Packagelaya.mathsClasspublic class PointInheritancePoint Object Point 对象表示二维坐标系统中的某个位置,其中 x 表示水平轴,y 表示垂直轴。 Public Properties PropertyDefined By  x : ...

来源: Laya2.0_api 发布时间: 20190513

423. laya.ui.UIEvent [ 51%]

...All Classes | Index | Frames No Frames UIEventProperties | Methods | Constants Packagelaya.uiClasspublic class UIEventInheritanceUIEvent Event Object UIEvent 类用来定义UI组件类的事件类型。 Public Properties Hide Inherited Public Properties Show Inherited Public Properties Prope...

来源: Laya2.0_api 发布时间: 20190513

424. 加载-销毁Texture使用的图片资源 [ 51%]

...png"; private readonly PathFly:string = "../../res/fighter/fighter.atlas"; constructor() { //初始化引擎 Laya.init(Browser.clientWidth, Browser.clientHeight, WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = "showall"; Laya.stage.bgCol...

来源: Laya_示例 发布时间: 20260106

425. 取色器组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 51%]

...类,通过代码设定ColorPicker相关的属性。示例代码如下: const { regClass, property } = Laya; @regClass() export class UI_ColorPicker extends Laya.Script { private skin: string = "atlas/comp/colorPicker.png"; constructor() { super(); } // 组件被激活后执行,此时所有节...

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

426. Scene.open打不开场景问题 [ 51%]

...经Laya2.7.1对比发现Laya2.8.0beta中Scene类中有一句this._setBit(Const.NOT_READY, true)换位置了,把Laya2.8.0beta的换成Laya2.7.1一样的位置这个问题就没了,麻烦Laya官方人员解答一下这个是bug还是故意这样设置的呢? 附件 : --> 1.png 2.png 2020-09-24 ...

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

427. spine动画放大后,遮罩显示不正常 [ 51%]

...的TestScene.scene文件 export default class GameUI extends Laya.Scene { constructor() { super(); //设置单例的引用方式,方便其他类引用 GameUI.instance = this; //关闭多点触控,否则就无敌了 Laya.MouseManager.multiTouchEnabled = false; //加载场景文件 this.loadScene(...

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

428. 按钮组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 51%]

...暴露的属性入口中。在脚本文件中添加如下示例代码: const { regClass, property } = Laya; @regClass() export class NewScript extends Laya.Script { @property({ type: Laya.Button }) public btn: Laya.Button; //组件被激活后执行,此时所有节点和组件均已创建完毕...

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

429. Spine动画烘焙插件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 51%]

...) 方法二: 通过脚本中代码添加,示例代码如下所示: const { regClass, property } = Laya; @regClass() export class SpineTest extends Laya.Script { //组件被启用后执行,例如节点被添加到舞台后 onEnable(): void { //加载预制体文件 Laya.loader.load("resourc...

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

430. 如何使用TS的命名空间(namespace)? [ 51%]

...。我布吉岛哎。我还是用的namespace。   export namespace mvc{ const commandMap = {}; export function registerCommand(){ //doSomething }; export interface ICommand{ excute(type:string, params:any):void; } }   2019-09-21 0 0 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折...

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