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

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

1. Laya2.2问题,有没有遇到的? [ 100%]

...? 子域所有代码 (function () { 'use strict';  class GameConfig { constructor() { } static init() { var reg = Laya.ClassUtils.regClass; } } GameConfig.width = 640; GameConfig.height = 1136; GameConfig.scaleMode = "fixedwidth"; GameConfig.screenMode = "none"; GameConfig.alignV = "top"; GameCon...

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

2. Cannot read property 'load' of null [ 96%]

...null,为什么会出现为null的情况?  代码如下: class main{ constructor(){ MapManager.getInstance().LoadMapResource(); } } new main(); class MapManager { private static s_instance = null; public static getInstance():MapManager { if(null==this.s_instance) { this.s_instance=new MapManager...

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

3. @regClass编译报错! [ 96%]

... // src/MachineCtrl.ts   var MachineCtrl = class extends CtrlBase {     constructor() {       super();     }   };   __name(MachineCtrl, "MachineCtrl");    // src/funcccccc.ts   var funzzzzz = class {     constructor() {     }     static run(callBack, caller, time) {       new M...

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

4. 使用 addChild 加载界面后,绑定事件报错 [ 95%]

...如下: export default class GameStart extends ui.GameStartUI {     constructor() {         super();          this.btnStart.on(Laya.Event.CLICK, this, this.startGame);     }      startGame(): void {         //Laya.Scene.open("GameView.scene");         ...

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

5. 在UI类里调用启动类的静态函数失败了 [ 85%]

...态函数失败了 这是我的启动类 // 程序入口 class GameMain { constructor() { Laya.init(600, 400); Laya.stage.bgColor = "#123456"; Laya.loader.load([ { url: "res/beijing/beijing2.png", type: Laya.Loader.IMAGE }, { url: "res/atlas/comp.png", type: Laya.Loader.IMAGE }, { url: "res/atlas/co...

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

6. 通过laya设计模式制作的,要怎么给按钮绑定事件呢? [ 80%]

...我看一下 xdkaka • 2017-12-13 17:03 没办法发图了 class Main { constructor() { Laya.init(480, 852); Laya.stage.scaleMode = "showall"; Laya.stage.alignV = 'middle'; Laya.stage.alignH = 'center'; Laya.stage.screenMode = "vertical"; Laya.stage.bgColor = "#101825"...

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

7. Laya3D场景加载问题 [ 74%]

...<String> = [         "gate/Conventional/Test.ls",     ];     constructor() { super(); }     onAwake(): void {         Laya.loader.create(this.resource, Laya.Handler.create(this, this.onPreLoadFinish));     }     onPreLoadFinish() {         //初始化3D场景         ...

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

8. StaticModel_MeshSample例子运行不起来 [ 72%]

...odel_MeshSample例子运行不起来 class StaticModel_MeshSample {     constructor() {         Laya3D.init(0, 0,true);         Laya.stage.scaleMode = Laya.Stage.SCALE_FULL;         Laya.stage.screenMode = Laya.Stage.SCREEN_NONE;         Laya.Stat.show();         var...

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

9. 微信小游戏无法用bin目录调试,只能发布后在release/wxgame/中调试 [ 70%]

...on/",  运行报错 gameContext?id=1:58 libs/laya.ui.js: TypeError: Class constructor Component cannot be invoked without 'new' at new Widget (laya.ui.js:201) at laya.ui.js:349 at laya.ui.js:1 at wrapFn (gameContext?id=1:51) at require (VM505 WAGameSubContext.js:2) at a (VM505 WAGameSubContext.js:2...

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

10. 可以帮我测试一下吗? 使用mask的场景,放着就会出现记忆体用完的讯息? [ 69%]

...似问题。class GameLayer extends ui.GameLayerUI { private infos : any; constructor () { super (); this.infos = { rotation : 0 }; Laya.timer.frameLoop(1,this,()=> { this.infos.rotation += 1; if (this.infos.rotation >= 360) this.infos.rotation -= 360; this.IM_TURNTABLE.rotation = this.infos.r...

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