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

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

111. Laya2.0在src新建的脚本没有执行(教程里的hellolayabox.js) [ 70%]

...继承A.scene的页面UI类,如果是非分离模式,则可继承Laya.Script类;然后在编辑模式下拖动,若是分离模式,则将A.ts拖到A.scene的runtime里,若是非分离模式,则把A.ts拖到A.scene的层级管理器里,让它变成A.scene的顶层子元素(子UI的...

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

112. 位图切片组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 70%]

...Clip: const { regClass, property } = Laya; @regClass() export class NewScript extends Laya.Script { @property({ type: Laya.Clip }) public clip: Laya.Clip; //组件被激活后执行,此时所有节点和组件均已创建完毕,此方法只执行一次 onAwake(): void { this.clip.pos(Laya.stag...

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

113. 列表组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 70%]

...数据源。 const { regClass, property } = Laya; @regClass() export class Script extends Laya.Script { @property({ type: Laya.List }) list: Laya.List constructor() { super(); } // 组件被启用后执行,例如节点被添加到舞台后 onEnable(): void { // 给List对象赋值 var data: Array&...

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

114. laya2.0 编辑器不显示父类变量 [ 70%]

...a2.0 编辑器不显示父类变量 举个粒子 class Parent extends Laya.Script{ /** @prop {name:name, type:string}*/ public name; } class Child extends Parent{} 在编辑器中给对象挂child脚本,并没有显示父类的name对象。 2018-12-13 添加评论 免费帖 --> 分享 微博 QZONE...

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

115. 单选框组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 70%]

...Radio: const { regClass, property } = Laya; @regClass() export class NewScript extends Laya.Script { @property({ type: Laya.Radio }) public radio: Laya.Radio; //组件被激活后执行,此时所有节点和组件均已创建完毕,此方法只执行一次 onAwake(): void { this.radio.skin = "...

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

116. 发布微信小游戏运行错误,Class constructor xx cannot be invoked without 'new' [ 70%]

...物体挂在脚本的时候 比如有个脚本是: class Test extends Laya.Script3D{ }   如xxx是一个3D节点,代码里执行: let script:Test = xxx.addComponent(Test);   在web端没问题,在微信开发者工具里运行报错,已上传Demo项目 附件 : --> IdleDemo.zip 2020-03-09 ...

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

117. 资源加载 · LayaAir3.3 · 引擎文档 · LAYABOX [ 70%]

...Class, property } = Laya; @regClass() export class LoaderDemo extends Laya.Script { onAwake(): void { this.loadTexture("resources/image/monkey2.png", 500);//需要在resources/image放入相应的资源 this.loadTexture("https://layaair.com/3.x/demo/resources/res/apes/monkey2.png"); } /**加载并...

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

118. 字体切片组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 70%]

...ntClip: const { regClass, property } = Laya; @regClass() export class NewScript extends Laya.Script { @property( { type : Laya.FontClip } ) public fontclp: Laya.FontClip; constructor() { super(); } // 组件被激活后执行,此时所有节点和组件均已创建完毕,此方法只执行一...

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

119. LayaAir IDE 1.4.0新增功能 附加(扩展)脚本的使用 [ 69%]

LayaAir IDE 1.4.0新增功能 附加(扩展)脚本的使用 .script和.prop脚本结合IDE在代码层的使用方式 2016-10-14 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 2 个回复 cuixueying 赞同来自: SONIC3D...

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

120. 3D 鼠标检测 错乱 [ 69%]

...& (Laya.Stat.loopCount > mouseTouch._pressedLoopCount)){ var pressedScripts=pressedSprite._scripts; if (pressedScripts){ for (j=0,m=pressedScripts.length;j < m;j++) pressedScripts[j].onMouseDrag(); } }; var touchSprite=mouseTouch.sprite; if (touchSprite){ var scripts=touchSprite._scripts; ...

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