大约有 396 项符合查询结果, 库内数据总量为 31,580 项。 (搜索耗时: 0.0052 秒)
...Laya.Image; //组件被启用后执行,例如节点被添加到舞台后 onEnable(): void { //需要先加载图集再使用,注意,图集要放到resources目录下或者在构建发布配置项里手动添加为始终包含的资源目录 Laya.loader.load("resources/aaa/test.atlas").then(() ...
来源: Laya3.0_文档 发布时间: 20251128
...s/bg2.png"; //组件被启用后执行,例如节点被添加到舞台后 onEnable(): void { Laya.loader.load(this.backgroundTexture).then(() => { this.createLightOccluder(); this.createSpotLight(); this.createBackground(); }); } // 创建2D光遮挡器 createLightOccluder(): void { this.lightOc...
来源: Laya3.0_文档 发布时间: 20251010
...类型的输出引脚。 如图2-7给出的示例,当蓝图节点触发onEnable生命周期时,开始打印”game start“,然后等待2秒 (这里的add就是参数节点,将1+1的结果输入给waitTime),再顺序执行打印“3”,2秒过后打印“4”。 (图2-7) 2.2 蓝...
来源: Laya3.0_文档 发布时间: 20251010
...{type:Laya.UI3D}) private ui3d: Laya.UI3D; public animator: Laya.Animator; onEnable() { // 广告牌模式 this.ui3d.billboard = true; //获得状态机 this.animator = this.target.getComponent<Laya.Animator>(Laya.Animator); } } 最后来看看运行效果: (动图4-2) Copyright ©Layabo...
来源: Laya3.0_文档 发布时间: 20251010
...nts Packagelaya.uiClasspublic class ScaleBoxInheritanceScaleBox Box UIComponent Sprite Node EventDispatcher Object 自适应缩放容器,容器设置大小后,容器大小始终保持stage大小,子内容按照原始最小宽高比缩放 Public Properties Hide Inherited Public Properties Show...
来源: Laya2.0_api 发布时间: 20190513
...置。 Node addChildren(... args):void 批量增加子节点 Node addComponent(type:Class):* 添加组件。 Node addComponentIntance(comp:Component):* 添加组件实例。 Node addInputChild(node:Node):NodeNode callLater(method:Function, args:Array = null):void 延迟运行指定的函数。 ...
来源: Laya2.0_api 发布时间: 20190513
...awtocanvCtx Accessors active activeInHierarchy alpha blendMode cacheAs components contextHeight contextWidth customRenderEnable destroyed displayHeight displayWidth displayedInStage drawCallOptimize filters globalRotation globalScaleX globalScaleY graphics height hideFlags hitArea href innerHTML is3...
来源: Laya3.0_api 发布时间: 20231102
...背景色为场景高度 this.box_color_bg.height = Laya.stage.height; } onEnable() { this.init(); // 判定是注册还是忘记密码 if (GameData.I.isReg) { this._regMode(); } else { this._forgetMode(); } // 添加取消事件 this.lb_cancel.on(Laya.Event.CLICK, this, () => { // 返回登陆...
来源: Laya_社区 发布时间: 20200410
...awtocanvCtx Accessors active activeInHierarchy alpha blendMode cacheAs components contextHeight contextWidth customRenderEnable destroyed displayHeight displayWidth displayedInStage drawCallOptimize filters globalRotation globalScaleX globalScaleY graphics height hideFlags hitArea innerHTML is3D mas...
来源: Laya3.0_api 发布时间: 20231102
...置。 Node addChildren(... args):void 批量增加子节点 Node addComponent(type:Class):* 添加组件。 Node addComponentIntance(comp:Component):* 添加组件实例。 Node addInputChild(node:Node):NodeNode callLater(method:Function, args:Array = null):void 延迟运行指定的函数。 ...
来源: Laya2.0_api 发布时间: 20190513