大约有 4,111 项符合查询结果, 库内数据总量为 31,722 项。 (搜索耗时: 0.0098 秒)
Laya_社区(3330) Laya2.0_文档(296) Laya_示例(141) Laya3.0_文档(118) Laya2.0_示例(117) Laya3.0_api(94) Laya2.0_api(9) laya_api(6)
...L); //设置舞台背景色 Laya.stage.bgColor = "#ffffff"; //原始位图 this.createImg(100,50); //红色滤镜 this.creteRedFilter(); //灰色滤镜 this.createGrayFilter(); } /**创建位图**/ private createImg(w:number,h:number):Laya.Sprite{ var Img:Laya.Sprite = new Laya.Sprite(); //添加到...
来源: Laya_社区 发布时间: 20200522
...手动监听Laya.stage.on(Laya.Event.RESIZE,,)来二次适配吗 // this.imgBG.left = 0 ; // this.imgBG.right = 0 ; // this.imgBG.top = 0 ; // this.imgBG.bottom = 0 ; 还有一个就是 layoutEnabled 属性 在什么情况用! 2017-09-18 添加评论 免费帖 --> 分享 微博 QZONE ...
来源: Laya_社区 发布时间: 20170918
... } onStart():void{ this.lab=this.owner as Laya.Label; } onUpdate():void{ if(this.lab==null){ console.log("lab为空"); return; } ...
来源: Laya_社区 发布时间: 20200602
...向laya的正方向,在场景里面创建出来2个, 第一个: this._mainPlayer.transform.position = new Vector3( 0,0,1 ); 第二个: this._npc.transform.position = new Vector3( 0,0,4 ); 然后调用: this._npc.transform.lookAt( this._mainPlayer.transform.position,new Laya.Vector3(0...
来源: Laya_社区 发布时间: 20180925
...ng"); // Laya.stage.addChild(box); bg1.loadImage("../bin/background.png"); this.addChild(bg1); bg2.loadImage("../bin/background.png"); bg2.pos(0,-852); this.addChild(bg2); 用this.addchild老是出错 2016-09-26 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请...
来源: Laya_社区 发布时间: 20160926
...ned class GameLogin extends ui.login.login_bgUI { constructor() { super(); this.btn_register.on("click", this, this.ToRegisterPage); } ToRegisterPage() : void { this.loadScene("login/register_page"); } } //调用on的时候 直接会报Cannot read property 'on' of undefined 我再把生成的u...
来源: Laya_社区 发布时间: 20181207
...leMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Stat.show(); this.setup(); } setup() { const Sprite = Laya.Sprite, Tween = Laya.Tween; let terminalX = 200; let characterA = this.createCharacter("res/cartoonCharacters/1.png"); characterA.pivot(46.5, 50); characterA.y = 100; let characte...
来源: Laya2.0_示例 发布时间: 20260303
...无法获取高度 var roleAni = new Laya.Animation(); roleAni.loadImages( this.aniUrls( v1, v2, tip, frames ) ).play(); roleAni.pos(x,y); this.root.addChild( roleAni ); roleAni.pivotY = roleAni.getBounds().height; console.log("---> ", roleAni.getBounds() ); 打印为 ---> Rectangle {x: 0, y:...
来源: Laya_社区 发布时间: 20170824
...变成了window,所以你需要绑定下作用域。onAssetsLoaded.bind(this) 2017-09-27 1 4 分享 微博 QZONE 微信 Monica - 知识达人 赞同来自: 你AS中是怎么写的? 2017-09-27 0 1 分享 微博 QZONE 微信 ljy328803417 赞同来自: 如图 2017-09-27 0 7 分享 微博 QZONE 微...
来源: Laya_社区 发布时间: 20170927
...这里监听循环按钮 for (let i: number = 1; i <= 2; i++) { let e = this.typeBox.getChildByName('btn' + i) as Laya.Image; console.log(e); e.on(Laya.Event.CLICK, this, this.onBtnClick); } 按钮事件 private onBtnClick(event:Laya.Event): void { le...
来源: Laya_社区 发布时间: 20190802