92 lines
3.3 KiB
JavaScript
92 lines
3.3 KiB
JavaScript
"use strict";
|
|
cc._RF.push(module, '61d4ccY2ztLMYIh8WvqPPAw', 'GameAppStart');
|
|
// Script/module/GameStart/GameAppStart.ts
|
|
|
|
"use strict";
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
var GameConfig_1 = require("../Config/GameConfig");
|
|
var HttpUtil_1 = require("../Crypto/HttpUtil");
|
|
var AudioManager_1 = require("../Music/AudioManager");
|
|
var Notification_1 = require("../Notification/Notification");
|
|
var Storage_1 = require("../Storage/Storage");
|
|
var GameTool_1 = require("../Tool/GameTool");
|
|
window.initMgr = function () {
|
|
if (cc.fx) {
|
|
return;
|
|
}
|
|
cc.fx = {};
|
|
console.log("1初始化");
|
|
//基础状态信息
|
|
cc.fx.StateInfo = {
|
|
debugMode: true,
|
|
networkConnected: true,
|
|
networkType: 'none',
|
|
isOnForeground: true //当前是否是在前台
|
|
};
|
|
//应用系统信息
|
|
//配置文件
|
|
cc.fx.GameConfig = GameConfig_1.GameConfig;
|
|
cc.fx.HttpUtil = HttpUtil_1.default;
|
|
cc.fx.GameTool = GameTool_1.GameTool;
|
|
cc.fx.AudioManager = AudioManager_1.default;
|
|
cc.fx.Notifications = Notification_1.Notifications;
|
|
cc.fx.StorageMessage = Storage_1.StorageMessage;
|
|
cc.fx.ShareInfo = {
|
|
queryId: -1 //分享id
|
|
};
|
|
cc.fx.Message = {
|
|
control: "10001",
|
|
startGame: "10002",
|
|
next: "10003" //传递执行下一个格子洪水流过
|
|
};
|
|
/*
|
|
* 客户端埋点分享类型
|
|
*/
|
|
cc.fx.BurialShareType = {
|
|
Default: "default",
|
|
Invite: "invite",
|
|
DailyInviteRoomJoin: 'invite_join_room',
|
|
DailyInviteFriend: 'invite_friend',
|
|
DailyInviteGroup: 'invate_group',
|
|
DailyInviteGroupAlive: 'invate_alive',
|
|
DailyInviteGroupReward: 'invate_rewared',
|
|
DailyInviteGroupBox: 'invate_box',
|
|
DailyInviteGroupBall: 'invate_ball',
|
|
MatchResult: 'matchResult',
|
|
MatchFix5: 'MatchFix5',
|
|
MatchFix20: 'MatchFix20',
|
|
MatchFix100: 'MatchFix100',
|
|
MatchFix500: 'MatchFix500',
|
|
NewerRedEnvelope: 'newerRedEnvelope',
|
|
CoinRoomResult: 'coinRoomResult',
|
|
HighRate: "highRate",
|
|
CoinRoomWinStreak: 'coinRoomWinStreak',
|
|
CoinRoomBankruptcy1: 'coinRoomBankruptcy1',
|
|
CoinRoomBankruptcy2: 'coinRoomBankruptcy2',
|
|
CoinRoomBankruptcy3: 'coinRoomBankruptcy3',
|
|
};
|
|
/*
|
|
* 分享到哪儿给奖励 group frined all
|
|
*/
|
|
cc.fx.ShareWhereReward = {
|
|
Group: "group",
|
|
Friend: "friend",
|
|
All: "all",
|
|
};
|
|
//用于存储消息的ID
|
|
cc.fx.storageType = cc.Enum({
|
|
storageTypeCustom: 1000101,
|
|
});
|
|
//用于存储提示语 按照步骤提示
|
|
cc.fx.tipType = cc.Enum({
|
|
tipOne: '神农氏回到家中,开始整理今天收集来的物品。当他第一次拿出或说出一种植物时,请告诉他这是新植物。',
|
|
tipTwo: '如果他拿出或说出的植物你今天看到过,请告诉他上次是看到的;如果你听他说过,则请告诉他上次是听到的。',
|
|
tipErrNew: '这是这局游戏第一次出现{植物}',
|
|
tipErrOld: '{植物}刚才出现过呢',
|
|
tipErrHear: '上次遇到{植物}时,似乎不是听到的吧',
|
|
tipErrSee: '上次遇到{植物}时,似乎不是看到的吧',
|
|
tipErrLast: '之前确实看到过{植物},但最近一次似乎不是看到的呢',
|
|
});
|
|
};
|
|
|
|
cc._RF.pop(); |