大约有 2,280 项符合查询结果, 库内数据总量为 30,778 项。 (搜索耗时: 0.0066 秒)
Laya_社区(1494) Laya2.0_文档(259) Laya_示例(138) Laya2.0_示例(101) Laya3.0_api(80) Laya2.0_api(74) laya_api(70) Laya3.0_文档(64)
...Info.width; this._body.height = this._objectInfo.templateInfo.height; this.addChild(this._body); this.on(Event.MOUSE_OVER, this, this.__onMouseOverHole); this.on(Event.MOUSE_OUT, this, this.__onMouseOutHole); } this.pos(this._objectInfo.templateInfo.x, this._objectInfo.templateInfo.y); } private __o...
来源: Laya_社区 发布时间: 20180308
... bg.skin = "res/img/loadingBg.jpg"; Laya.stage.addChild(bg); //实例一个文本 txt = new Text(); txt.text = "适配模式("+Stage.SCALE_EXACTFIT+") "; txt.bold = true; txt.pos(1...
来源: Laya2.0_文档 发布时间: 20200307
...res/apes/monkey2.png"; let gap = 150; this.ape1 = new Sprite(); Laya.stage.addChild(this.ape1); this.ape1.loadImage(monkey2Path); // 设置轴心点为中心 this.ape1.pivot(55, 72); this.ape1.pos(Laya.stage.width / 2 - gap, Laya.stage.height / 2); // 不设置轴心点默认为左上角 this.ape2 =...
来源: Laya2.0_示例 发布时间: 20241117
... = new Laya.Animation(); this.body.y = -100; this.body.interval = 50; this.addChild(this.body); this.body.play(0, true, "hero_fly"); } private body: Laya.Animation; private onBtn2Click(): void { this.body.destroyChildren(); this.body.clear(); this.body.destroy(); } 调试面板中的sprite个DrwaCal...
来源: Laya_社区 发布时间: 20170615
...p() { var bg = new Sprite(); bg.loadImage("../../res/bg2.png"); Laya.stage.addChild(bg); bg2 = new Sprite(); bg2.loadImage("../../res/bg2.png"); Laya.stage.addChild(bg2); bg2.scale(3, 3); //创建mask maskSp = new Sprite(); maskSp.loadImage("../../res/mask.png"); maskSp.pivot(50, 50); //设置mask b...
来源: Laya_示例 发布时间: 20241117
....screenMode = Laya.Stage.SCREEN_NONE; initShader(); var scene = Laya.stage.addChild(new Laya.Scene()); var camera = scene.addChild(new Laya.Camera(0, 0.1, 100)); camera.transform.translate(new Laya.Vector3(0, 0.5, 1.5)); camera.addComponent(CameraMoveScript); var layaMonkey = scene.addChild(new Laya...
来源: Laya_示例 发布时间: 20241117
...plete() { var dialog = new Dialog(); var bg = new Image(assets[0]); dialog.addChild(bg); var button = new Button(assets[1]); button.name = Dialog.CLOSE; button.pos(DIALOG_WIDTH - CLOSE_BTN_WIDTH - CLOSE_BTN_PADDING, CLOSE_BTN_PADDING); dialog.addChild(button); dialog.dragArea = "0,0," + DIALOG_WIDTH...
来源: Laya_示例 发布时间: 20241117
...teLabel(text) { const Text = Laya.Text; let label = new Text(); Laya.stage.addChild(label); label.text = text; label.color = "white"; label.fontSize = 20; return label; } createInput() { const Input = Laya.Input; let input = new Input(); Laya.stage.addChild(input); input.size(200, 30); input.borderC...
来源: Laya2.0_示例 发布时间: 20241117
... bg.skin = "res/img/loadingBg.jpg"; Laya.stage.addChild(bg); //实例一个文本 this.txt = new Text(); this.txt.text = "适配模式("+this.modes+") "; this.txt.bold = true; thi...
来源: Laya2.0_文档 发布时间: 20200307
....Stage.SCREEN_NONE; Laya.Stat.show(); var scene: Laya.Scene = Laya.stage.addChild(new Laya.Scene()) as Laya.Scene; this._outHitAllInfo = new Array<Laya.RaycastHit>(); //初始化照相机 this.camera = scene.addChild(new Laya.Camera(0, 0.1, 100)) as Laya.Camera; this.camera.transform.tra...
来源: Laya_社区 发布时间: 20180820