大约有 401 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0038 秒)
...代码设定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
... 保存场景后,在RuntimeScript.ts中添加如下代码: const { regClass } = Laya; import { RuntimeScriptBase } from "./RuntimeScript.generated"; @regClass() export class RuntimeScript extends RuntimeScriptBase { onAwake(): void { this.closeBtn.on(Laya.Event.CLICK, this, () => { this.close...
来源: Laya3.0_文档 发布时间: 20251024
...置见下图代码和附件DEMO中的TestScene.scene文件 export default class GameUI extends Laya.Scene { constructor() { super(); //设置单例的引用方式,方便其他类引用 GameUI.instance = this; //关闭多点触控,否则就无敌了 Laya.MouseManager.multiTouchEnabled = false; //...
来源: Laya_社区 发布时间: 20190730
...al.__super.call(this); this.setShaderName("CustomShader"); } Laya.class(CustomMaterial, "CustomMaterial", Laya.BaseMaterial); CustomMaterial.DIFFUSETEXTURE = 1; CustomMaterial.NORMALTEXTURE = 2; CustomMaterial.ALPHATESTVALUE = 0; CustomMaterial.prototype.getDiffuseTexture = function (...
来源: Laya_社区 发布时间: 20170526
...就出问题了。是要把unity场景导入到laya2.6. export default class SceneLoad extends Laya.Script{ constructor(){ super(); } onAwake(){ Laya.Scene3D.load("res/LayaScene_demo/Android/demo.ls",Laya.Handler.create(this,function(scene...
来源: Laya_社区 发布时间: 20200516
...pescript //继承自AnimatorStateScript(动画状态脚本) export default class AnimatorStateScriptTest extends Laya.AnimatorStateScript { constructor() { super(); this._text = null; } get text() { return this._text; } set text(value) { this._text = value; } /** * 动画状态开始时执行。 */ ...
来源: Laya2.0_文档 发布时间: 20210715
...pescript //继承自AnimatorStateScript(动画状态脚本) export default class AnimatorStateScriptTest extends Laya.AnimatorStateScript { private _text:Laya.Text; constructor() { super(); } get text():Laya.Text { return this._text; } set text(value) { this._text = value; } /** * 动画状态开始...
来源: Laya2.0_文档 发布时间: 20210715
...a.Script _start和_update以及_lateupdate不执行是什么原因呢? class b extends Laya.Script{ _initialize(owner:Laya.Sprite3D){ super._initialize(owner); //加打印可以执行 } _start(state:Laya.RenderState):void{ //加打印不执行 ...
来源: Laya_社区 发布时间: 20180423
...a.ani.bone.Templet; import laya.events.Event; public class CombatRole extends BaseRole { private var _templet:Templet; public function CombatRole() { super(); initView(); } ...
来源: Laya_社区 发布时间: 20170204
...,现在有插件开发,修改源码会有问题): export default class GifView extends Laya.Clip { /** *开始帧位置 * * @private * @memberof GifView */ private frameIndex = 0; /** *结束帧...
来源: Laya_社区 发布时间: 20201211