大约有 427 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0040 秒)
...js 当点击它们无法获知,我点的是哪个,代码 如下 export default class btn1 extends Laya.Script { constructor(){super();} onEnable(){} onClick(){ alert("id="+this.id); //这里有一个id,但是系统自动生成的,无法获知这个id代表哪个按钮被点(因为我有4...
来源: Laya_社区 发布时间: 20181029
...本场景添加脚本为组件报错 报一个窗口提示: export default class Start extends Laya.Script { constructor() { super(); } /** * 组件被激活后执行,此时所有节点和组件均已创建完毕,次方法只执行一次 */ onAwake(): void { } /** * 第一次执行upd...
来源: Laya_社区 发布时间: 20181013
...不影响事件的触发这里是随便取的名。 ```typescript export default class SceneScript extends Laya.Script3D { constructor(){ super(); //用于表现的方法 this.showMsgFunc = null; } //对应unity添加的AnimationEvent的动画事件函数,名字是可以对应上的 ShowMsg() { co...
来源: Laya2.0_文档 发布时间: 20210715
...不影响事件的触发这里是随便取的名。 ```typescript export default class SceneScript extends Laya.Script3D { //用于表现的方法 public showMsgFunc; constructor(){ super(); } //对应unity添加的AnimationEvent的动画事件函数,名字是可以对应上的 ShowMsg(){ console....
来源: Laya2.0_文档 发布时间: 20210715
...anel显示,要么显示一部分或者消失,测试代码如下 export default class ClipView extends Laya.Sprite { constructor() { super(); this.init(); } init() { let bg = new Laya.Sprite(); bg.graphics.drawRect(0, 0, 500, 500, '#aaa'); this.addChild(bg); this.panel = new Laya.Panel(); this.pa...
来源: Laya_社区 发布时间: 20210427
...derShape.ts:22 创建一个新的 SphereColliderShape 实例。 Parameters Default value radius: number = 0.5 半径。 Returns SphereColliderShape Properties needsCustomCollisionCallback needsCustomCollisionCallback: boolean = false Inherited from CompoundColliderShape.needsCustomCollisionCallback ...
来源: Laya3.0_api 发布时间: 20231115
...rIn); } import { ui } from "./ui/layaMaxUI"; export default class ShopDialog extends ui.ShopDialogUI { constructor() { super(); this.popupEffect = Laya.Handler.create(this, this.showEffect); this.closeEffect = Laya.Handler.create(this, this.hideEffect); this.btnClose.on(Laya.E...
来源: Laya_社区 发布时间: 20190121
...擎之前设置。 Hierarchy Config Index Properties FPS animationInterval defaultFont defaultFontSize destroyResourceImmediatelyDefault fixedFrames isAlpha isAntialias isDepth isStencil isfailIfMajorPerformanceCaveat powerPreference premultipliedAlpha preserveDrawingBuffer printWebglOrder useRetina...
来源: Laya3.0_api 发布时间: 20231115
...derShape.ts:16 创建一个新的 SphereColliderShape 实例。 Parameters Default value radius: number = 0.5 半径。 Returns CannonSphereColliderShape Properties needsCustomCollisionCallback needsCustomCollisionCallback: boolean = false Inherited from CannonColliderShape.needsCustomCollisionCallb...
来源: Laya3.0_api 发布时间: 20231102
...aya/d3/core/BaseCamera.ts:307 创建一个 BaseCamera 实例。 Parameters Default value nearPlane: number = 0.3 近裁面。 Default value farPlane: number = 1000 远裁面。 Returns BaseCamera Properties Optional _extra _extra: INodeExtra Inherited from Node._extra Defined in laya/display/Node.ts...
来源: Laya3.0_api 发布时间: 20231115