大约有 2,411 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0067 秒)
Laya_社区(1453) Laya2.0_文档(592) Laya3.0_文档(80) Laya3.0_api(65) Laya_示例(61) Laya2.0_api(60) laya_api(54) Laya2.0_示例(46)
...ity: 1 }, { url: "../../res/threeDimen/scene/TerrainScene/Assets/HeightMap.png", clas: Laya.Texture2D, priority: 1, params: [true] }, { url: "../../res/threeDimen/scene/TerrainScene/Assets/AStarMap.png", clas: Laya.Texture2D, priority: 1, params: [true] } ]; Laya.loader.create(resource, Laya.Handler...
来源: Laya_示例 发布时间: 20251130
... 研究了鼠标样式,查了论坛看到有说Mouse.cursor="url('mouse.png')";这样使用的,但是试了试不管用。折腾了一下看看为啥失效了,试了几十次终于搞定可以使用了 Laya.Mouse.cursor = 'url("comp/image.png"),auto',或者Laya.Mouse.cursor = 'url(comp/image...
来源: Laya_社区 发布时间: 20180126
...":2,"child":[{"type":"Button","props":{"y":616,"x":296,"skin":"comp/button.png","name":"butStart","label":"label"},"compId":3}],"loadList":["comp/button.png"],"loadList3D":[]}; constructor(){ super()} createChildren():void { super.createChildren(); this.createView(GameSceneuiUI.uiView); } } REG("ui....
来源: Laya_社区 发布时间: 20200228
...teApes() { const Sprite = Laya.Sprite; let monkey2Path = "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...
来源: Laya2.0_示例 发布时间: 20251130
获取Image宽度的问题 当我从代码中创建图片(img_bg.png)添加到场景中时,在代码中获取图片的width就等于0当我提前在场景中放置好一个相同的图片资源(img_bg.png),然后再在代码中创建一个图片(img_bg.png)时,就可以获取到img_bg的width...
来源: Laya_社区 发布时间: 20191126
...这个方案,将会导致如下图一样的显示效果。  (图1) 在图1中,按 iPhone3GS的`320 × 480`进行全屏设计,那在iPhone4下的显示效果则如图1左侧,原来的满屏内容只占了四分之一,其余部分留空。而按iPhone4分辨率 `640 × ...
来源: Laya2.0_文档 发布时间: 20210715
...动释放掉所有没有使用且没有 **上锁** 的资源。 (图1) 如图1所示,我们地图上添加了一个按钮。并且给按钮添加了以下事件。 > 以下代码节选自官方示例([demo地址](https://layaair.ldc.layabox.com/demo2/?language=ch&category=3d&group=...
来源: Laya2.0_文档 发布时间: 20210715
...":2,"child":[{"type":"Button","props":{"y":616,"x":296,"skin":"comp/button.png","name":"butStart","label":"label"},"compId":3}],"loadList":["comp/button.png"],"loadList3D":[]}; constructor(){ super()} createChildren():void { super.createChild...
来源: Laya_社区 发布时间: 20200228
...只执行一次 onAwake(): void { this.hscroll.skin = "atlas/comp/hscroll.png";//滚动条皮肤 this.hscroll.width = 300;//滚动条的宽度 this.hscroll.pos(300, 300);//滚动条的位置 this.hscroll.min = 0;//滑块的最小滚动位置 this.hscroll.max = 10;//滑块的最大滚动位置 this.h...
来源: Laya3.0_文档 发布时间: 20251010
...只执行一次 onAwake(): void { this.vscroll.skin = "atlas/comp/vscroll.png";//滚动条皮肤 this.vscroll.width = 300;//滚动条的宽度 this.vscroll.pos(300, 300);//滚动条的位置 this.vscroll.min = 0;//滑块的最小滚动位置 this.vscroll.max = 10;//滑块的最大滚动位置 this.v...
来源: Laya3.0_文档 发布时间: 20251010