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

大约有 387 项符合查询结果, 库内数据总量为 30,786 项。 (搜索耗时: 0.0036 秒)

1. 屏幕适配-对齐模式 [ 100%]

...00); Laya.stage.scaleMode = Stage.SCALE_NOSCALE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.bgColor = "#232628"; })(); })();module laya { import Stage = Laya.Stage; export class SmartScale_Align_Contral { constructor() { Laya.init(100, 100); Laya.stage...

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

2. 屏幕适配-对齐模式 [ 99%]

... WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = Stage.SCALE_NOSCALE; Laya.stage.bgColor = "#232628"; } } new SmartScale_Align_Contral();module laya { import Stage = Laya.Stage; export class SmartScale_Align_Contral { constructor() { Lay...

来源: Laya2.0_示例 发布时间: 20241124

3. UI-Image [ 97%]

... WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; setup(); })(); function setup() { var dialog = new Image("../../res/ui/dialog (3).png"); dialog.pos(165, 62.5); Laya.stage.addChild(dia...

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

4. UI-Image [ 96%]

... WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Stat.show(); this.setup(); } setup() { const Image = Laya.Image; let dialog = new Image("res/ui/dialog (3).png"); Laya.stage.addChild(d...

来源: Laya2.0_示例 发布时间: 20241124

5. 区块地图-PerspectiveWall [ 96%]

... WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.bgColor = "#232628"; createMap(); })(); function createMap() { tiledMap = new TiledMap(); tiledMap.createMap("../../res/tiledMap/perspective_walls.json", new Rectangle(0, 0, Laya.stage.width, Laya.sta...

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

6. 区块地图-PerspectiveWall [ 96%]

... WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; this.createMap(); Laya.stage.on(Laya.Event.CLICK, this, this.onStageClick); } createMap() { const TiledMap = Laya.TiledMap, Rectangle =...

来源: Laya2.0_示例 发布时间: 20241124

7. 区块地图-带动画的地图 [ 96%]

... WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; createMap(); })(); function createMap() { tiledMap = new TiledMap(); tiledMap.createMap("../../res/tiledMap/orthogonal-test-movelayer.j...

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

8. 区块地图-带动画的地图 [ 96%]

... WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; this.createMap(); } createMap() { const TiledMap = Laya.TiledMap; let tiledMap = new TiledMap(); tiledMap.createMap("res/tiledMap/ortho...

来源: Laya2.0_示例 发布时间: 20241124

9. 屏幕适配-自动横屏 [ 96%]

... WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = "showall"; Laya.stage.screenMode = Stage.SCREEN_HORIZONTAL; Laya.stage.bgColor = "#232628"; showText(); })(); function showText() { var text = new Text(); text.text = "Orientation-Landscap...

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

10. 屏幕适配-自动竖屏 [ 96%]

... WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = "showall"; Laya.stage.screenMode = Stage.SCREEN_VERTICAL; Laya.stage.bgColor = "#232628"; showText(); })(); function showText() { var text = new Text(); text.text = "Orientation-Portrait";...

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