大约有 692 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0051 秒)
Laya_社区(333) Laya3.0_api(89) Laya2.0_api(69) Laya2.0_文档(65) laya_api(61) Laya3.0_文档(41) Laya2.0_示例(19) Laya_示例(15)
...远 在某个地方使用var pos:Point = img.localToGlobal(new Point(img.width/2, img.height/2));转换坐标 结果是完全正确的。但最近又有地方需要用到 于是写了trace(soil_1.localToGlobal(new Point(soil_1.width/2, soil_1.height/2)));结果与预期相差很远。结果与预期...
来源: Laya_社区 发布时间: 20181219
...据IDE设置初始化引擎 if (window["Laya3D"]) Laya3D.init(GameConfig.width, GameConfig.height); else Laya.init(GameConfig.width, GameConfig.height, Laya["WebGL"]); Laya.stage.scaleMode = GameConfig.scaleMode; Laya.stage.screenMode = GameConfig.screenMode; Laya.stage.alignV = GameConfig.alignV; L...
来源: Laya2.0_文档 发布时间: 20210715
...ize(); _proMask = new Sprite(); _proMask.graphics.drawRect(0, 0, _progress.width, _progress.height); _proMask.scaleX = 0; _progress.mask = _proMask; _bar.stateNum = 1; } override protected function createChildren():void { super.createChildren(); var index:Number = getChildIndex(_bg); addChildAt(_pro...
来源: Laya_社区 发布时间: 20170327
...tReceive = true; } // 生成一个矩形 private generateRectVerticesAndUV(width: number, height: number): Laya.Mesh2D { const vertices = new Float32Array(4 * 5); const indices = new Uint16Array(2 * 3); let index = 0; vertices[index++] = 0; vertices[index++] = 0; vertices[index++] = 0; vertices[inde...
来源: Laya3.0_文档 发布时间: 20251010
... 网页: 模拟器: 真机测试: 有两端黑边 Browser.width获取不到真正的手机宽度值 想请问下各位大佬 怎么能获取到手机的宽度值来计算出比例 TEST2为demo,apk为打包的apk 附件 : --> Test2.rar apk.rar 2020-05-15 添加评论 免费帖 ...
来源: Laya_社区 发布时间: 20200515
...tatic tempTexture: Laya.Texture; /**截图 */ public static drawScreenshot(width, height, x, y) { if (!SwitchHelper.screenDraw) { return null; } if (!this.tempTexture2D) { this.tempTexture2D = new Laya.Texture2D(system.width, system.height); } if (!this.tempTexture) { this.tempTexture = new Laya.T...
来源: Laya_社区 发布时间: 20191016
...temRender = Item; list.repeatX = 1; list.repeatY = 4; list.x = (Laya.stage.width - WID) / 2; list.y = (Laya.stage.height - HEI * list.repeatY) / 2; // 使用但隐藏滚动条 list.vScrollBarSkin = ""; list.selectEnable = true; list.selectHandler = new Handler(this, this.onSelect); list.renderHandle...
来源: Laya2.0_示例 发布时间: 20251130
...性 y 的值,用于控制 textInput 对象的显示位置。 textInput.width = 300;//设置 textInput 的宽度。 textInput.height = 200;//设置 textInput 的高度。 textInput.bgColor = "#c30c30"; Laya.stage.addChild(textInput);//将 textInput 添加到显示列表。 } private function Text_I...
来源: Laya2.0_文档 发布时间: 20210715
...temRender = Item; list.repeatX = 1; list.repeatY = 4; list.x = (Laya.stage.width - WID) / 2; list.y = (Laya.stage.height - HEI * list.repeatY) / 2; // 使用但隐藏滚动条 list.vScrollBarSkin = ""; list.selectEnable = true; list.selectHandler = new Handler(this, onSelect); list.renderHandler = n...
来源: Laya_示例 发布时间: 20251130
...this.tiledMap.createMap("desert.json", new Laya.Rectangle(0, 0, Laya.stage.width, Laya.stage.height), Laya.Handler.create(this,this.loadedMap)); } loadedMap(){ this.sp=new Laya.Sprite(); this.sp.graphics.drawRect(0,0,100,100,"#FF0000"); var mapLayer = this.tiledMap.getLayerByIndex(1);...
来源: Laya_社区 发布时间: 20171125