import { LayerConf, LayerType } from "../layer/LayerManager";

export enum ViewID {

    LoginUI = 1,                    //登录
    LoadingUI,                  //加载
    MaskUI,                  //蒙板 
    TempTipsUI,                 //提示
    SelectServer,                 //服务器列表
    GameWind,                 // 子游戏窗口

    TowerUI,  //塔防
    ZombieUI,  //打僵尸

    MailMain,                     //邮箱
    MailDetail,                   //邮件
    Bulletin,                     //公告

    CommonTips,                   //通用提示
    ItemMsg,                      //物品详情

    HeroList,                     //英雄列表
    HeroAttr,                     //英雄养成
    EquipChoose,                  //装备选择
    EquipStrong,                  //装备强化
}

export let Layer_Conf: { [key: number]: LayerConf } = {

    [ViewID.LoginUI]: { bundle: "package", url: "prefab/login/LoginUI", type: LayerType.UI },
    [ViewID.LoadingUI]: { bundle: "package", url: "prefab/login/LoadingUI", type: LayerType.UI },
    [ViewID.MaskUI]: { bundle: "package", url: "prefab/ui/relogin/MaskUI", type: LayerType.Notice,special: true, preload: true  },
    [ViewID.TempTipsUI]: { bundle: "package", url: "prefab/ui/TempTipsUI", type: LayerType.Notice },
    [ViewID.GameWind]: { bundle: "package", url: "prefab/ui/GameUI", type: LayerType.UI, anim: 0 },
	[ViewID.TowerUI]: { bundle: "package", url: "prefab/ui/tower/tower", type: LayerType.Game, anim: 0 },
    [ViewID.ZombieUI]: { bundle: "package", url: "prefab/ui/tower/zombie", type: LayerType.Game, anim: 0 },

    [ViewID.MailMain]: { bundle: "mail", url: "prefab/MailMain", type: LayerType.UI, anim: 2 },
    [ViewID.MailDetail]: { bundle: "mail", url: "prefab/MailDetail", type: LayerType.UI, anim: 2 },
    [ViewID.SelectServer]: { bundle: "package", url: "prefab/login/SelectServer", type: LayerType.UI, anim: 2 },
    [ViewID.Bulletin]: { bundle: "package", url: "prefab/login/Bulletin", type: LayerType.UI, anim: 2 },

    [ViewID.CommonTips]: { bundle: "package", url: "prefab/ui/tips/CommomTips", type: LayerType.UI, anim: 2 },
    [ViewID.ItemMsg]: { bundle: "common", url: "prefab/ItemMsg", type: LayerType.UI, anim: 2 },

    [ViewID.HeroList]: { bundle: "hero", url: "prefab/HeroList", type: LayerType.Game, anim: 0 },
    [ViewID.HeroAttr]: { bundle: "hero", url: "prefab/HeroAttr", type: LayerType.Game, anim: 0 },
    [ViewID.EquipChoose]: { bundle: "hero", url: "prefab/EquipChoose", type: LayerType.Game, anim: 0 },
    [ViewID.EquipStrong]: { bundle: "hero", url: "prefab/EquipStrong", type: LayerType.Game, anim: 0 },
};