大约有 1,253 项符合查询结果, 库内数据总量为 30,900 项。 (搜索耗时: 0.0050 秒)
...) 示例代码如下: const { regClass, property } = Laya; @regClass() export class ScriptA extends Laya.Script { //declare owner : Laya.Sprite3D; @property( { type: Laya.Box } ) private box: Laya.Box; constructor() { super(); } onStart(): void { //加载预制体文件 Laya.loader.load("resourc...
来源: Laya3.0_文档 发布时间: 20241014
...写了一个模块 MyModuleimport { com} from "../libs/protobuf/area.js"; export function testProto():void { console.log("call testProto"); var ProtobufUtil = com.bee.protobuf; let msg = ProtobufUtil.ProtoArea.create(); let buffer = ProtobufUtil.ProtoArea.encode(msg).finish(); let decode = ProtobufU...
来源: Laya_社区 发布时间: 20171115
...脚本名不影响事件的触发这里是随便取的名。 ```typescript export default class SceneScript extends Laya.Script3D { //用于表现的方法 public showMsgFunc; constructor(){ super(); } //对应unity添加的AnimationEvent的动画事件函数,名字是可以对应上的 ShowMsg(){...
来源: Laya2.0_文档 发布时间: 20210715
...) 示例代码如下: const { regClass, property } = Laya; @regClass() export class ScriptA extends Laya.Script { //declare owner : Laya.Sprite3D; @property( { type: Laya.Box } ) private box: Laya.Box; constructor() { super(); } onStart(): void { //加载预制体文件 Laya.loader.load("resourc...
来源: Laya3.0_文档 发布时间: 20250214
...e layaair Options All Public Public/Protected All Inherited Externals Only exported Menu Globals "laya/d3/core/MeshFilter" MeshFilter Class MeshFilter MeshFilter 类用于创建网格过滤器。 Hierarchy Component MeshFilter Index Constructors constructor Properties _extra _singleton owner runInEd...
来源: Laya3.0_api 发布时间: 20231115
...ext = Laya.Text; import Browser = Laya.Browser; import WebGL = Laya.WebGL; export class Text_Overflow { constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(600, 300, WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = Stage.S...
来源: Laya_示例 发布时间: 20250220
...超出panel显示,要么显示一部分或者消失,测试代码如下 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(); ...
来源: Laya_社区 发布时间: 20210427
...aya.HttpRequest; import Browser = Laya.Browser; import WebGL = Laya.WebGL; export class Network_POST { private hr: HttpRequest; private logger: Text; constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Browser.clientHeight, WebGL); Laya.stage.alignV = Stage.ALIGN...
来源: Laya_示例 发布时间: 20250220
...e layaair Options All Public Public/Protected All Inherited Externals Only exported Menu Globals "laya/d3/component/LODGroup" LODGroup Class LODGroup SpotLight 类用于构建LOD组件 Hierarchy Component LODGroup Implements IBoundsCell Index Constructors constructor Properties _extra _singleton own...
来源: Laya3.0_api 发布时间: 20231115
...e.linearIn); } 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_社区 发布时间: 20190121