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

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

491. ui.list的高度如果是cell高度的3.5倍,但是repeatY只是1-2的时候还是会可以上下滑动 [ 55%]

...以上下滑动 个人猜测,感觉这个可能是changeCells里面计算this._cellOffset的方法里面乘数是Math.max而不是Math.min得出来的数值导致的问题(2.0.0 laya.ui.js 8451行) 附件 : --> 2019-04-18 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结...

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

492. 分享:如何使用IDE创建的动画.ani文件进行显示! [ 55%]

...用到的资源 Laya.loader.load("res/atlas/fly.json", Laya.Handler.create(this, onAssetLoaded), null, Laya.Loader.ATLAS); function onAssetLoaded() { var ani=new Laya.Animation();//创建animation实例 ani.loadAnimation('Ani.ani');//加载IDE制作的动画 Laya.stage.addChild(ani);//显示动画 a...

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

493. 时间轴动画(ActionScript-LayaAir基础篇(AS3)-动画基础) [ 55%]

...onLoad回调方法 Laya.loader.load("res/atlas/ui.atlas", Handler.create(this, onLoaded)); ``` 第二步:创建Animation实例,加载动画文件 ```java //创建一个Animation实例 var tl:Animation = new Animation(); //加载动画文件 tl.loadAnimation("TimeLine.ani"); ``` 第三步:添...

来源: Laya2.0_文档 发布时间: 20210715

494. 原生js传图片給laya的sprite,怎么设置其等比缩小? [ 55%]

...片还是100%显示,$pic.loadImage(_pic, 14, 192, 0, 0, Handler.create(this, function(){     $pic.height = 246;     $pic.scaleX = $pic.scaleY;     trace("$pic.width:" + $pic.width); })); 请问:我用原生上传了一张图片,然后传給layaAir,这个图片的scale是未知的,我...

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

495. 【laya2.0】加载并且显示图片,并且让该图片居于舞台中央,怎么写? [ 55%]

...e.addChild(logo); logo.loadImage("res/atlas/test.png", Laya.Handler.create(this, function(){ console.log("complete!!"); logo.x= Laya.stage.width/2-logo.width/2; logo.y= Laya.stage.height/2-logo.height/2; //logo.pos(Laya.stage.width/2-logo.width/2,Laya.stage.height/2-logo.height/2); })); 2018-10-10 0...

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

496. 为什么谷歌浏览器调试可以显示这些文字打包后却没有了 [ 55%]

...t;"; gRoomView.chatBox.height = 1; } public SysSay(txt:string):void { this.AddChat(0, "法官", txt); } public PlayerSay(msg:any):void { this.AddChat(msg['from_client_seatsno'], msg['from_client_name'], msg['content']); } private AddChat(seat:number, name:string, txt:string) { let pao...

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

497. 屏幕适配-自动横屏 [ 55%]

...tage.screenMode = Stage.SCREEN_HORIZONTAL; Laya.stage.bgColor = "#232628"; this.showText(); } private showText(): void { var text: Text = new Text(); text.text = "Orientation-Landscape"; text.color = "gray"; text.font = "Impact"; text.fontSize = 50; text.x = Laya.stage.width - text.width >> 1; text....

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

498. 屏幕适配-自动竖屏 [ 55%]

....stage.screenMode = Stage.SCREEN_VERTICAL; Laya.stage.bgColor = "#232628"; this.showText(); } private showText(): void { var text: Text = new Text(); text.text = "Orientation-Portrait"; text.color = "gray"; text.font = "Impact"; text.fontSize = 50; text.x = Laya.stage.width - text.width >> 1; text.y...

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

499. 3d物理 刚体旋转bug 2.17到2.12都有 [ 55%]

...置计算。将以下代码复制到分支处理内: var shapeOffset = this._colliderShape.localOffset; var position = transform.position; var btPosition = PhysicsComponent._btVector30; if (shapeOffset.x !== 0 || shapeOffset.y !== 0 || shapeOffset.z !== 0) { var physicPosition = PhysicsComponent._...

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

500. 引擎的text类中有没有直接读取Json文件的函数 [ 54%]

...Demo() { Laya.init(500,400); Laya.loader.load("unpack.json",Handler.create(this,onLoaded),null,Loader.JSON); } private function onLoaded():void { var json:JSON=Laya.loader.getRes("unpack.json"); var str:String=JSON.stringify(json); trace(str); } } } 2017-08-07 0 0 分享 微博 QZONE 微信 为什...

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