|
@@ -34,7 +34,7 @@ export function getGameResList() {
|
|
{ url: "asset/fgui/game_atlas0_3.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas0_3.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas10.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas10.png", type: Laya.Loader.IMAGE },
|
|
//
|
|
//
|
|
- // { url: "asset/fgui/game_atlas_kupwv4tc.png", type: Laya.Loader.IMAGE },
|
|
|
|
|
|
+ // { url: "asset/fgui/game_atlas_kupwv4tc.png", type: Laya.Loader.IMAGE },
|
|
//
|
|
//
|
|
{ url: "asset/fgui/game_atlas_n43d3v3.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas_n43d3v3.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas_n43d3v4.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas_n43d3v4.png", type: Laya.Loader.IMAGE },
|
|
@@ -43,8 +43,8 @@ export function getGameResList() {
|
|
{ url: "asset/fgui/game_atlas_p4tr42b.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas_p4tr42b.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas_p4tr42c.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas_p4tr42c.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas_p4tr42e.png", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas_p4tr42e.png", type: Laya.Loader.IMAGE },
|
|
- // { url: "asset/fgui/game_atlas_p7rrv4r8.png", type: Laya.Loader.IMAGE },
|
|
|
|
- // { url: "asset/fgui/game_atlas_p7rrv4rq.png", type: Laya.Loader.IMAGE },
|
|
|
|
|
|
+ // { url: "asset/fgui/game_atlas_p7rrv4r8.png", type: Laya.Loader.IMAGE },
|
|
|
|
+ // { url: "asset/fgui/game_atlas_p7rrv4rq.png", type: Laya.Loader.IMAGE },
|
|
//
|
|
//
|
|
{ url: "asset/fgui/game_atlas_rz5r457.jpg", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas_rz5r457.jpg", type: Laya.Loader.IMAGE },
|
|
//
|
|
//
|
|
@@ -54,17 +54,26 @@ export function getGameResList() {
|
|
{ url: "asset/fgui/game_atlas_wehi3uc.jpg", type: Laya.Loader.IMAGE },
|
|
{ url: "asset/fgui/game_atlas_wehi3uc.jpg", type: Laya.Loader.IMAGE },
|
|
//
|
|
//
|
|
//加载json
|
|
//加载json
|
|
- // { url: "res/json/npc.json", type: Laya.Loader.JSON },
|
|
|
|
- // { url: "res/json/classicCfg.json", type: Laya.Loader.JSON },
|
|
|
|
- // { url: "res/json/levelCfg.json", type: Laya.Loader.JSON },
|
|
|
|
- // { url: "res/json/placeBallCfg.json", type: Laya.Loader.JSON },
|
|
|
|
|
|
+ // { url: "res/json/npc.json", type: Laya.Loader.JSON },
|
|
|
|
+ // { url: "res/json/classicCfg.json", type: Laya.Loader.JSON },
|
|
|
|
+ // { url: "res/json/levelCfg.json", type: Laya.Loader.JSON },
|
|
|
|
+ // { url: "res/json/placeBallCfg.json", type: Laya.Loader.JSON },
|
|
|
|
|
|
{ url: "res/font/arial.ttf", type: Laya.Loader.FONT },
|
|
{ url: "res/font/arial.ttf", type: Laya.Loader.FONT },
|
|
]
|
|
]
|
|
}
|
|
}
|
|
function initCallback() {
|
|
function initCallback() {
|
|
window["DataMgr"] = DataMgr;
|
|
window["DataMgr"] = DataMgr;
|
|
-
|
|
|
|
|
|
+
|
|
|
|
+ // try {
|
|
|
|
+
|
|
|
|
+ // Laya.loader.load("res/font/arial.ttf", Laya.Handler.create(this, this.onFontLoaded));
|
|
|
|
+ // console.log("zh: gameInit.ts constructor加载arial字体成功");
|
|
|
|
+ // } catch (error) {
|
|
|
|
+ // console.log("zh: gameInit.ts constructor加载arial字体失败");
|
|
|
|
+ // }
|
|
|
|
+
|
|
|
|
+
|
|
DataMgr.Init();
|
|
DataMgr.Init();
|
|
Moyu.init(getPlat(), this, () => {
|
|
Moyu.init(getPlat(), this, () => {
|
|
DataMgr.isNewDay();
|
|
DataMgr.isNewDay();
|
|
@@ -82,7 +91,14 @@ function initCallback() {
|
|
//加载loading界面
|
|
//加载loading界面
|
|
xGame.uiMgr.Show(UILoading)
|
|
xGame.uiMgr.Show(UILoading)
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+function onFontLoaded(): void {
|
|
|
|
+ try {
|
|
|
|
+ Laya.Text.defaultFont = "arial";
|
|
|
|
+ console.log("zh: onFontLoaded 设置arial字体成功");
|
|
|
|
+ } catch (error) {
|
|
|
|
+ console.log("zh: constructor onFontLoaded加载arial字体失败");
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
|
|
export function loadSubRes(callback) {
|
|
export function loadSubRes(callback) {
|
|
var tab = ["asset", "res", "spine"];
|
|
var tab = ["asset", "res", "spine"];
|