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

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

1. 调试-帧率统计 [ 100%]

...how(Browser.clientWidth - 120 >> 1, Browser.clientHeight - 100 >> 1); })();module laya { import Browser = Laya.Browser; import Stat = Laya.Stat; export class Debug_FPSStats { constructor() { Laya.init(Browser.clientWidth, Browser.clientHeight); Stat.show(Browser.clientWidth - 120 >> 1, Browser.clien...

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

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

...ge.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.scaleMode = Stage.SCALE_NOSCALE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.alignV = Sta...

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

3. 屏幕适配-缩放-No Scale [ 91%]

...() { rect.x = Laya.stage.width / 2; rect.y = Laya.stage.height / 2; } })();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; export class SmartScale_Scale_NOSCALE { private rect: Sprite; constructor() { Laya.init(550, 400); Laya.stage.scaleMode = Stage.SCALE_NOSCALE; Laya.stage.b...

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

4. 屏幕适配-缩放-No Border [ 91%]

...() { rect.x = Laya.stage.width / 2; rect.y = Laya.stage.height / 2; } })();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; export class SmartScale_Scale_NOBORDER { private rect: Sprite; constructor() { Laya.init(550, 400); Laya.stage.scaleMode = Stage.SCALE_NOBORDER; Laya.stage...

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

5. 屏幕适配-缩放-Show All [ 91%]

...() { rect.x = Laya.stage.width / 2; rect.y = Laya.stage.height / 2; } })();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; export class SmartScale_Scale_SHOW_ALL { private rect: Sprite; constructor() { Laya.init(550, 400); Laya.stage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage....

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

6. 屏幕适配-缩放-Extract Fit [ 91%]

...() { rect.x = Laya.stage.width / 2; rect.y = Laya.stage.height / 2; } })();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; export class SmartScale_Scale_EXTRACT_FIT { private rect: Sprite; constructor() { Laya.init(550, 400); Laya.stage.scaleMode = Stage.SCALE_EXACTFIT; Laya.st...

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

7. UI-Image [ 90%]

...alog (3).png"); dialog.pos(165, 62.5); Laya.stage.addChild(dialog); } })();module laya { import Stage = Laya.Stage; import Image = Laya.Image; import WebGL = Laya.WebGL; export class UI_Image { constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(550, 400, WebGL); Laya.stage.alignV = ...

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

8. 区块地图-PerspectiveWall [ 89%]

...", new Rectangle(0, 0, Laya.stage.width, Laya.stage.height), null); } })();module laya { import Stage = Laya.Stage; import TiledMap = Laya.TiledMap; import Rectangle = Laya.Rectangle; import Browser = Laya.Browser; import WebGL = Laya.WebGL; export class TiledMap_PerspectiveWall { private tiledMap: ...

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

9. 区块地图-带动画的地图 [ 87%]

...", new Rectangle(0, 0, Laya.stage.width, Laya.stage.height), null); } })();module laya { import Stage = Laya.Stage; import TiledMap = Laya.TiledMap; import Rectangle = Laya.Rectangle; import WebGL = Laya.WebGL; export class TiledMap_AnimationTile { private tiledMap: TiledMap; constructor() { // 不...

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

10. 加载-多种类型资源加载 [ 86%]

...r robotTexture = Loader.getRes(ROBOT_TEXTURE_PATH); // 使用资源 } })();module laya { import Loader = Laya.Loader; import Handler = Laya.Handler; export class Loader_MultipleType { private ROBOT_DATA_PATH: string = "../../res/skeleton/robot/robot.bin"; private ROBOT_TEXTURE_PATH: string = "../../...

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