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

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

871. 关于 this.destroy(true); [ 89%]

关于 this.destroy(true); 这个调用是否会把 当前类的所有子对象和自己删除 然后也会清除里面的各种监听事件么?原理大概是怎么样的? 2017-12-14 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链...

来源: Laya_社区 发布时间: 20171214

872. 屏幕适配-缩放-Show All [ 89%]

...aya.stage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; this.createCantralRect(); } private createCantralRect(): void { this.rect = new Sprite(); this.rect.graphics.drawRect(-100, -100, 200, 200, "gray"); Laya.stage.addChild(this.rect); this.updateRectPos(); } private updateRectPo...

来源: Laya_示例 发布时间: 20260303

873. 屏幕适配-缩放-Extract Fit [ 89%]

...ya.stage.scaleMode = Stage.SCALE_EXACTFIT; Laya.stage.bgColor = "#232628"; this.createCantralRect(); } private createCantralRect(): void { this.rect = new Sprite(); this.rect.graphics.drawRect(-100, -100, 200, 200, "gray"); Laya.stage.addChild(this.rect); this.updateRectPos(); } private updateRectPo...

来源: Laya_示例 发布时间: 20260303

874. 导出微信小游戏 微信的api前面会自动加上文件夹名? view.wx.getSystemInfoSync() 怎么解决自动加"this. " 或者有时自动加上各种文件夹名? [ 89%]

...动加上文件夹名? view.wx.getSystemInfoSync() 怎么解决自动加"this. " 或者有时自动加上各种文件夹名? 导出微信小游戏 微信的api前面会自动加上文件夹名? view.wx.getSystemInfoSync() 怎么解决自动加"this. " 或者有时自动加上各种文件夹名?this....

来源: Laya_社区 发布时间: 20180605

875. 微信小游戏,实现监听前后台切换 [ 89%]

...身是否有解决方案啊  wxhelper.jsclass WXHELPER { constructor () { this._isWxContext = !!window.wx } onShow (callback) { if (!this._isWxContext) return window.wx.onShow(callback) } onHide (callback) { if (!this._isWxContext) return window.wx.onHide(callback) } offShow (callback) { if (!this....

来源: Laya_社区 发布时间: 20181101

876. Tween 缓动过程有触发回调函数么 [ 89%]

...属性列表,比如{x:100,y:20,ease:Ease.backOut,complete:Handler.create(this,onComplete),update:new Handler(this,onComplete)}。   update这个 数值改变就会触发回调,也就是过程中的回调 2018-01-09 0 1 分享 微博 QZONE 微信 kezhiyu 赞同来自: let a = new Tween() let da...

来源: Laya_社区 发布时间: 20180109

877. 监听不到Laya.Event.RESIZE事件 [ 89%]

...不到Laya.Event.RESIZE事件 init():void{ Laya.stage.on(Laya.Event.RESIZE,this,this.onStageChange); } protected onStageChange(event:Event):void { this.bg.y = 180; alert("11111111111111") var desWidth:Number; var desHeight:Number; //获取窗口显示区的宽度。 desWidth=window.innerWidth; //获...

来源: Laya_社区 发布时间: 20170322

878. matter 2d 碰撞检测 [ 89%]

...onGameOver不是函数,麻烦有时间的大佬看看,很奇怪:   this.Matter.Events.on(this._engine, 'collisionActive', this.onCollision);   private onCollision(event): void { for(var i = 0; i < event.pairs.length; i++) {  var pair = event.pairs[i];  if(pair.bodyA.label === 'gun' &amp...

来源: Laya_社区 发布时间: 20180524

879. [LayaAir3]3D场景里面鼠标感应区域 3.2.1跟3.3不同 [ 89%]

... Laya.loader.load("RenderTexture.rendertexture", null, Laya.Handler.create(this, null, null, false)).then(() => { this.spRole.texture = Laya.loader.getRes("RenderTexture.rendertexture"); //设置纹理的宽高为舞台大小,这样才不会拉伸变形 this.spRole.texture.sourceWidth = Laya.st...

来源: Laya_社区 发布时间: 20250109

880. 如何在代码中new Poly [ 89%]

...new Poly 如题,然后设置它的  renderType   这样也不行 : this.imgExpedition = new component.HomeScaleFilterImg(3, 655, "home/imgExpedition.png", 0); this._sprHome.addChildAt(this.imgExpedition, 0); this.homeScaleFilterImgList.push(this.imgExpedition);  Laya.timer.once(2000, this, ()...

来源: Laya_社区 发布时间: 20180507