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

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

641. laya.display.Node [ 28%]

... 获得所属场景。 Implementation     public function get scene():*Constructor DetailNode()Constructorpublic function Node()Method DetailaddChild()method public function addChild(node:Node):Node 添加子节点。 Parameters node:Node — 节点对象 ReturnsNode — 返回添加的节点 ad...

来源: Laya2.0_api 发布时间: 20190513

642. 3D灯光与阴影 · LayaAir3.3 · 引擎文档 · LAYABOX [ 28%]

...“引擎API使用示例” export class MultiLight extends BaseScript { constructor() { super(); } onAwake(): void { var moveScript: LightMoveScript = this.camera.addComponent(LightMoveScript); var moverLights: Laya.Sprite3D[] = moveScript.lights; var offsets: Vector3[] = moveScript.offsets; var mo...

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

643. laya.ui.Dialog_API3.0 [ 28%]

...aya.utils.Handler; class Dialog_Example { private dialog: Dialog_Instance; constructor() { Laya.init(640, 800);//设置游戏画布宽高。 Laya.stage.bgColor = "#efefef";//设置画布的背景颜色。 Laya.loader.load("resource/ui/btn_close.png", Handler.create(this, this.onLoadComplete));//加...

来源: Laya3.0_api 发布时间: 20231115

644. laya.ui.TextInput_API3.0 [ 28%]

....TextInput; import Handler = laya.utils.Handler; class TextInput_Example { constructor() { Laya.init(640, 800);//设置游戏画布宽高、渲染模式。 Laya.stage.bgColor = "#efefef";//设置画布的背景颜色。 Laya.loader.load(["resource/ui/input.png"], Handler.create(this, this.onLoadComp...

来源: Laya3.0_api 发布时间: 20231115

645. laya.ui.TextArea_API3.0 [ 27%]

...ui.TextArea; import Handler = laya.utils.Handler; class TextArea_Example { constructor() { Laya.init(640, 800);//设置游戏画布宽高、渲染模式。 Laya.stage.bgColor = "#efefef";//设置画布的背景颜色。 Laya.loader.load(["resource/ui/input.png"], Handler.create(this, this.onLoadComp...

来源: Laya3.0_api 发布时间: 20231115

646. 插件开发说明 · LayaAir3.3 · 引擎文档 · LAYABOX [ 27%]

...egClass() export class DemoPreviewPlugin extends IEditorEnv.AssetPreview { constructor() { super(); this.sprite.graphics.drawCircle(100, 100, 50, "#ffff00"); this.sprite.size(100, 100); } async setAsset(asset: IEditorEnv.IAssetInfo): Promise<any> { this.renderTarget = this.sprite; } } 显示...

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

647. laya.d3.math.Matrix4x4 [ 26%]

...ty Detailelementspropertypublic var elements:Float32Array矩阵元素数组Constructor DetailMatrix4x4()Constructorpublic function Matrix4x4(m11:Number = 1, m12:Number = 0, m13:Number = 0, m14:Number = 0, m21:Number = 0, m22:Number = 1, m23:Number = 0, m24:Number = 0, m31:Number = 0, m32:Number = 0,...

来源: Laya2.0_api 发布时间: 20190513

648. 组件脚本的内置方法 · LayaAir3.3 · 引擎文档 · LAYABOX [ 26%]

... */ private _text: Laya.Text; /**盒子等级 */ private _level: number; constructor() { super(); } //组件被启用后执行 onEnable(): void { this._level = Math.round(Math.random() * 5) + 1; this._text = this.owner.getChildByName("levelTxt") as Laya.Text; this._text.text = this._level + ""; } //...

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

649. 2D性能优化 · LayaAir3.3 · 引擎文档 · LAYABOX [ 26%]

...脑性能而定,本例为10000): class Test { private text:Laya.Text; constructor() { Laya.init(550,400,Laya.WebGL); Laya.Stat.show(); var textBox=new Laya.Sprite(); for(var i=0;i<10000;i++) { this.text=new Laya.Text(); this.text.text=(Math.random()*100).toFixed(0); this.text.color="#CCCCCC";...

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

650. laya.display.Stage_API3.0 [ 26%]

...态更改帧率有利于改进手机耗电。 Hierarchy Sprite Stage Index Constructors constructor Properties _extra _ownGraphics _scene _skinBaseUrl _url autoSize canvasDegree canvasRotation designHeight designWidth focus hitTestPrior mouseThrough name renderingEnabled screenAdaptationEnabled tag ...

来源: Laya3.0_api 发布时间: 20231115