Esempio n. 1
0
    private void InitConfig()
    {
        UIConfig.defaultFont = "default";
        UIConfig.defaultComboBoxVisibleItemCount = 5;
        UIConfig.loaderErrorSign = "ui://go13tig0sdw37t";        //"ui://e44hzvgsj4v12c";//ui://e44hzvgsj4v12c
        UIConfig.allowSoftnessOnTopOrLeftSide = true;

        UIObjectFactory.SetLoaderExtension(typeof(BaseLoader));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ComNumeric"), typeof(ComNumeric));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ComGold"), typeof(ComGold));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ComCoin"), typeof(ComCoin));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ComIcon"), typeof(ComIcon));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ComCard"), typeof(ComCard));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ComProgress"), typeof(ComProgress));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ComBigIcon"), typeof(ComBigIcon));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ProgressBar"), typeof(ComProgressBar));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ComExp"), typeof(ComExp));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ComTabEffect"), typeof(ComTabEffect));
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ComRankScore"), typeof(ComRankScore));
        //配置
        PlatForm.inst.CheckPlatForm();
        PlatForm.inst.CheckLanguage();
        PlatForm.inst.CheckNetwork();
        PlatForm.inst.GetSdk().Init("");
        this.initQueue.Next();
    }
Esempio n. 2
0
    void Awake()
    {
        Application.targetFrameRate = 60;

        UIPackage.AddPackage("TurnCard");
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("TurnCard", "Card_Comp"), typeof(OneCard));
    }
Esempio n. 3
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(UI_ProgressBar.URL, typeof(UI_ProgressBar));
     UIObjectFactory.SetPackageItemExtension(UI_ObjItem.URL, typeof(UI_ObjItem));
     UIObjectFactory.SetPackageItemExtension(UI_CloseButton.URL, typeof(UI_CloseButton));
     UIObjectFactory.SetPackageItemExtension(UI_Button.URL, typeof(UI_Button));
 }
Esempio n. 4
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(SelectServer.URL, typeof(SelectServer));
     UIObjectFactory.SetPackageItemExtension(ServerItem.URL, typeof(ServerItem));
     UIObjectFactory.SetPackageItemExtension(RolePanel.URL, typeof(RolePanel));
     UIObjectFactory.SetPackageItemExtension(LoginPlant.URL, typeof(LoginPlant));
 }
Esempio n. 5
0
    void Awake()
    {
        Application.targetFrameRate = 60;
        Stage.inst.onKeyDown.Add(OnKeyDown);

        UIObjectFactory.SetPackageItemExtension("ui://PullToRefresh/Header", typeof(ScrollPaneHeader));
    }
Esempio n. 6
0
 protected override void Awake()
 {
     base.Awake();
     SoundManager.Instance.Init();
     UIConfig.tooltipsWin = "ui://ResComponent/ToolTips";
     UIConfig.bringWindowToFrontOnClick = false;
     UIObjectFactory.SetPackageItemExtension("ui://BagMenu/SlotButton", typeof(SlotButton));
     UIObjectFactory.SetPackageItemExtension("ui://ShopMenu/ShopListItem", typeof(ShopListItem));
     UIObjectFactory.SetPackageItemExtension("ui://SkillMenu/SkillListItem", typeof(SkillListItem));
     UIObjectFactory.SetPackageItemExtension("ui://MainMenu/SlotButton", typeof(ShortCutButton));
     UIWindowManager.Instance.Init(uiWindowTypes);
     PlayerStatusManager.Instance.Init();
     GameObject.Instantiate(Players[(int)(PlayerStatusManager.Instance.playerInfo.PlayerType) - 1]);
     MouseCursorManager.Instance.Init();
     TaskManager.Instance.Init();
     ItemManager.Instance.Init();
     EnemyManager.Instance.Init();
     BagManager.Instance.Init();
     ShopManager.Instance.Init();
     EquipmentManager.Instance.Init();
     SkillManager.Instance.Init();
     ShortCutManager.Instance.Init();
     SoundManager.Instance.PlayBg("BGM-Ingame");
     UIWindowManager.Instance.CloseWindow(UIWindowTypes.SelectMenuWindow);
     UIWindowManager.Instance.OpenWindow(UIWindowTypes.MainMenuWindow);
 }
Esempio n. 7
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(UI_BagButton.URL, typeof(UI_BagButton));
     UIObjectFactory.SetPackageItemExtension(UI_BagGridSub.URL, typeof(UI_BagGridSub));
     UIObjectFactory.SetPackageItemExtension(UI_BagWin.URL, typeof(UI_BagWin));
     UIObjectFactory.SetPackageItemExtension(UI_WindowFrame.URL, typeof(UI_WindowFrame));
     UIObjectFactory.SetPackageItemExtension(UI_CloseButton.URL, typeof(UI_CloseButton));
     UIObjectFactory.SetPackageItemExtension(UI_dot.URL, typeof(UI_dot));
     UIObjectFactory.SetPackageItemExtension(UI_JiNengYeMianAnNiu.URL, typeof(UI_JiNengYeMianAnNiu));
     UIObjectFactory.SetPackageItemExtension(UI_DuanZaoYeMianAnNiu.URL, typeof(UI_DuanZaoYeMianAnNiu));
     UIObjectFactory.SetPackageItemExtension(UI_JiangLiYeMianAnNiu.URL, typeof(UI_JiangLiYeMianAnNiu));
     UIObjectFactory.SetPackageItemExtension(UI_JunTuanYeMianAnNiu.URL, typeof(UI_JunTuanYeMianAnNiu));
     UIObjectFactory.SetPackageItemExtension(UI_RenWuYeMianAnNiu.URL, typeof(UI_RenWuYeMianAnNiu));
     UIObjectFactory.SetPackageItemExtension(UI_JingJiYeMianAnNiu.URL, typeof(UI_JingJiYeMianAnNiu));
     UIObjectFactory.SetPackageItemExtension(UI_JinHuaYeMianAnNiu.URL, typeof(UI_JinHuaYeMianAnNiu));
     UIObjectFactory.SetPackageItemExtension(UI_ShangDianYeMian.URL, typeof(UI_ShangDianYeMian));
     UIObjectFactory.SetPackageItemExtension(UI_mailItem.URL, typeof(UI_mailItem));
     UIObjectFactory.SetPackageItemExtension(UI_SheZhi.URL, typeof(UI_SheZhi));
     UIObjectFactory.SetPackageItemExtension(UI_TiaoZhanBOSS.URL, typeof(UI_TiaoZhanBOSS));
     UIObjectFactory.SetPackageItemExtension(UI_TanSuoShiJie.URL, typeof(UI_TanSuoShiJie));
     UIObjectFactory.SetPackageItemExtension(UI_WuDaoDaHui.URL, typeof(UI_WuDaoDaHui));
     UIObjectFactory.SetPackageItemExtension(UI_TongTianMoTa.URL, typeof(UI_TongTianMoTa));
     UIObjectFactory.SetPackageItemExtension(UI_bloodbar.URL, typeof(UI_bloodbar));
     UIObjectFactory.SetPackageItemExtension(UI_HeadBar.URL, typeof(UI_HeadBar));
     UIObjectFactory.SetPackageItemExtension(UI_mainstage.URL, typeof(UI_mainstage));
 }
Esempio n. 8
0
 public void Show()
 {
     UIPackage.AddPackage("SD/ShuDu");
     UIObjectFactory.SetPackageItemExtension(strItemUrl, typeof(ShuItem));
     GComponent com = UIManager.inst.CreateObject<GComponent>("ShuDu", "GamePanel");
     GRoot.inst.AddChild(com);
     com.SetSize(GRoot.inst.width, GRoot.inst.height);
     com.AddRelation(GRoot.inst, RelationType.Size);
     com.Center();
     GList list = com.GetChild("n1").asList;
     list.RemoveChildrenToPool();
     list.defaultItem = strItemUrl;
     ShuData.inst.InitData();
     for (int i = 0; i < 9; i++)
     {
         for (int j = 0; j < 9 ; j++)
         {
             ShuItem item = list.AddItemFromPool() as ShuItem;
             item.Init(i, j);
         }
     }
     GRoot.inst.DispatchEvent("ShuUpdate");
     list.onClickItem.Add(ItemClick);
     for(int i = 0; i < 10; i++)
     {
         ExchangeRow(Random.Range(0, 9), Random.Range(0, 9));
         ExchangeCol(Random.Range(0, 9), Random.Range(0, 9));
     }
     GRoot.inst.DispatchEvent("ShuHide");
 }
Esempio n. 9
0
 void Awake()
 {
     UIPackage.AddPackage("UIPanel/UI");  //添加包
     UIObjectFactory.SetPackageItemExtension("ui://UI/ProductListItem", typeof(ProductListItem));
     UIManager.Instance.LoadUIPanel(UIPanelEnum.StartUI);
     //UIManager.Instance.LoadUIPanel(UIPanelEnum.MainUI);
 }
Esempio n. 10
0
    void Start()
    {
        Application.targetFrameRate = 60;
        GRoot.inst.SetContentScaleFactor(1136, 640);
        Stage.inst.onKeyDown.Add(OnKeyDown);

        UIPackage.AddPackage("UI/VirtualList");
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("VirtualList", "mailItem"), typeof(MailItem));

        _mainView = UIPackage.CreateObject("VirtualList", "Main").asCom;
        _mainView.fairyBatching = true;
        _mainView.SetSize(GRoot.inst.width, GRoot.inst.height);
        _mainView.AddRelation(GRoot.inst, RelationType.Size);
        GRoot.inst.AddChild(_mainView);

        _mainView.GetChild("n6").onClick.Add(() => { _list.AddSelection(500, true); });
        _mainView.GetChild("n7").onClick.Add(() => { _list.scrollPane.ScrollTop(); });
        _mainView.GetChild("n8").onClick.Add(() => { _list.scrollPane.ScrollBottom(); });

        _list = _mainView.GetChild("mailList").asList;
        _list.SetVirtual();

        _list.itemRenderer = RenderListItem;
        _list.numItems     = 1000;
    }
Esempio n. 11
0
 private void RegisterItemExtension()
 {
     UIObjectFactory.SetPackageItemExtension("ui://Home/Buff", typeof(BuffTip));
     UIObjectFactory.SetPackageItemExtension("ui://Home/Button_Attack", typeof(SkillButton));
     UIObjectFactory.SetPackageItemExtension("ui://Level/ThreeStar", typeof(ThreeStar));
     UIObjectFactory.SetPackageItemExtension("ui://Level/LevelItem", typeof(LevelItem));
 }
Esempio n. 12
0
 public static void Init()
 {
     //加载通用包 还有绑定通用组件等
     AppMain.Inst.ResMgr.AddUIPackage("Base");
     UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ShowMsgDialog"), typeof(ShowMsgDialog));
     UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("Base", "ShowTipDialog"), typeof(ShowTipDialog));
 }
Esempio n. 13
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(UI_Window.URL, typeof(UI_Window));
     UIObjectFactory.SetPackageItemExtension(UI_EnterButton.URL, typeof(UI_EnterButton));
     UIObjectFactory.SetPackageItemExtension(UI_GalaxyBg.URL, typeof(UI_GalaxyBg));
     UIObjectFactory.SetPackageItemExtension(UI_MainBg.URL, typeof(UI_MainBg));
 }
Esempio n. 14
0
    IEnumerator Start()
    {
        LoggerHelper.Instance.Startup();
        JsManager.Instance.Startup();

        //初始化FairyGUI
        GRoot.inst.SetContentScaleFactor(1280, 720, UIContentScaler.ScreenMatchMode.MatchWidthOrHeight);
        UIPackage.unloadBundleByFGUI = false;

        NTexture.CustomDestroyMethod = (Texture t) =>
        {
            Addressables.Release(t);
            Logger.Log(".... release addressable: " + t.name);
        };

        UIObjectFactory.SetPackageItemExtension(LaunchPage.URL, typeof(LaunchPage));
        UIObjectFactory.SetPackageItemExtension(UINoticeWin.URL, typeof(UINoticeWin));

        //加载FairyGUI Package
        AsyncOperationHandle <TextAsset> handle = Addressables.LoadAssetAsync <TextAsset>(fairy_package);

        yield return(handle);

        TextAsset pkgAsset = handle.Result;

        UIPackage.AddPackage(
            pkgAsset.bytes,
            "game",
            async(string name, string extension, Type type, PackageItem ite) => {
            Logger.Log($"{name}, {extension}, {type.ToString()}, {ite.ToString()}");

            if (type == typeof(Texture))
            {
                Texture t = await Addressables.LoadAssetAsync <Texture>(name + extension).Task;
                ite.owner.SetItemAsset(ite, t, DestroyMethod.Custom);
            }
        });
        Addressables.Release(handle);

        //加载更新界面
        launchPage = LaunchPage.CreateInstance();
        launchPage.Show();

        //Test
        UINoticeWin notice = UINoticeWin.CreateInstance();

        notice.ShowOneButton("test test", () => {
            notice.Hide();
        });
        yield return(notice.WaitForResponse());


        // 开始更新
        if (launchPage != null)
        {
            StartCoroutine(launchPage.CheckUpdate());
        }
        yield break;
    }
Esempio n. 15
0
    // Use this for initialization
    void Start()
    {
        PlayerPrefs.DeleteAll();
        UIPackage.AddPackage("FairyGUI/UIMain");
        UIObjectFactory.SetPackageItemExtension("ui://UIMain/ClickShower", typeof(ShowClickMask));
        hasSave = PlayerPrefs.GetInt("hasSave", 0);

        _main_menu = GetComponent <UIPanel> ().ui;
        _main_menu.GetController("c0").SetSelectedPage("unsave");
        if (hasSave > 0)
        {
            _main_menu.GetController("c0").SetSelectedPage("save");
        }
        _main_menu.GetChild("loadGame").onClick.Add(loadGame);
        _main_menu.GetChild("newGame").onClick.Add(newGame);
        _main_menu.GetChild("options").onClick.Add(options);
        _main_menu.GetChild("quit").onClick.Add(quit);

        //_main_menu.onClick.Add (OnClick);
        _main_menu.onClick.Add(OnClickShow);
        effect = _main_menu.GetChild("effect").asMovieClip;
//		ShowClickMask _maskLayer = (ShowClickMask)UIPackage.CreateObject ("UIMain", "ClickShower").asCom;
//		_maskLayer.SetSize(GRoot.inst.width, GRoot.inst.height);
//		_maskLayer.AddRelation(GRoot.inst, RelationType.Size);
//
//
//
//		GRoot.inst.AddChild(_maskLayer);
//		_main_menu.AddChild (mask);
//		Debug.Log (_main_menu.numChildren);
//		Debug.Log (mask.position);

        _mask = _main_menu.GetChild("mask").asGraph;


        _newHeroPanel = _main_menu.GetChild("newHeroPanel").asCom;
        _info         = _newHeroPanel.GetChild("info").asTextField;
        _desp         = _newHeroPanel.GetChild("desp").asTextField;

        _start_game = _newHeroPanel.GetChild("startGame").asLoader;
        _start_game.onClick.Add(delegate(EventContext context) {
            PlayerData.getInstance().heroIdx = choosedHeroIdx;
            enterGame();
        });

        _hero_list = _newHeroPanel.GetChild("hero_list").asList;
        _hero_list.SetVirtualAndLoop();

        _hero_list.itemRenderer = RenderHeroes;
        _hero_list.numItems     = GameStaticData.getInstance().heroes.Count;
        _hero_list.scrollPane.onScroll.Add(doHeroScrollEffect);
        _hero_list.scrollPane.onScrollEnd.Add(changeHeroDetail);
        doHeroScrollEffect();
        changeHeroDetail();
        {
            _info.text = GameStaticData.getInstance().heroes[choosedHeroIdx].name;
            _desp.text = GameStaticData.getInstance().heroes [choosedHeroIdx].desp;
        }
    }
Esempio n. 16
0
    void Awake()
    {
        UIPackage.AddPackage("UI/ModalWaiting");
        UIConfig.globalModalWaiting = UIPackage.GetItemURL("ModalWaiting", "GlobalModalWaiting");
        UIConfig.windowModalWaiting = UIPackage.GetItemURL("ModalWaiting", "WindowModalWaiting");

        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("ModalWaiting", "GlobalModalWaiting"), typeof(GlobalWaiting));
    }
Esempio n. 17
0
    void Awake()
    {
        UIPackage.AddPackage("UI/ModalWaiting");
        UIConfig.globalModalWaiting = "ui://ModalWaiting/GlobalModalWaiting";
        UIConfig.windowModalWaiting = "ui://ModalWaiting/WindowModalWaiting";

        UIObjectFactory.SetPackageItemExtension("ui://ModalWaiting/GlobalModalWaiting", typeof(GlobalWaiting));
    }
Esempio n. 18
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(UI_Scene.URL, typeof(UI_Scene));
     UIObjectFactory.SetPackageItemExtension(UI_UIMain.URL, typeof(UI_UIMain));
     UIObjectFactory.SetPackageItemExtension(UI_BuildingLevelUp.URL, typeof(UI_BuildingLevelUp));
     UIObjectFactory.SetPackageItemExtension(UI_BuildingOpen.URL, typeof(UI_BuildingOpen));
     UIObjectFactory.SetPackageItemExtension(UI_BuildingList.URL, typeof(UI_BuildingList));
 }
Esempio n. 19
0
    void Awake()
    {
        Application.targetFrameRate = 60;
        Stage.inst.onKeyDown.Add(OnKeyDown);

        UIPackage.AddPackage("UI/TurnCard");
        UIObjectFactory.SetPackageItemExtension(UIPackage.GetItemURL("TurnCard", "CardComponent"), typeof(Card));
    }
Esempio n. 20
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="url"></param>
 /// <param name="luaClass"></param>
 public static void SetExtension(string url, System.Type baseType, LuaFunction extendFunction)
 {
     UIObjectFactory.SetPackageItemExtension(url, () => {
         GComponent gcom = (GComponent)Activator.CreateInstance(baseType);
         gcom.data       = extendFunction;
         return(gcom);
     });
 }
Esempio n. 21
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(UI_ExploreSelectPupil.URL, typeof(UI_ExploreSelectPupil));
     UIObjectFactory.SetPackageItemExtension(UI_ExploreView.URL, typeof(UI_ExploreView));
     UIObjectFactory.SetPackageItemExtension(UI_EmptyPupilMan.URL, typeof(UI_EmptyPupilMan));
     UIObjectFactory.SetPackageItemExtension(UI_EmptyPupilWoman.URL, typeof(UI_EmptyPupilWoman));
     UIObjectFactory.SetPackageItemExtension(UI_PlaceSelectItem.URL, typeof(UI_PlaceSelectItem));
     UIObjectFactory.SetPackageItemExtension(UI_ExploreSuccessPanel.URL, typeof(UI_ExploreSuccessPanel));
 }
Esempio n. 22
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(UI_CommonTips.URL, typeof(UI_CommonTips));
     UIObjectFactory.SetPackageItemExtension(UI_StarLevel.URL, typeof(UI_StarLevel));
     UIObjectFactory.SetPackageItemExtension(UI_PanelFrameWithTitleAndClose.URL, typeof(UI_PanelFrameWithTitleAndClose));
     UIObjectFactory.SetPackageItemExtension(UI_PanelFrameDialog.URL, typeof(UI_PanelFrameDialog));
     UIObjectFactory.SetPackageItemExtension(UI_PanelFrameWithClose.URL, typeof(UI_PanelFrameWithClose));
     UIObjectFactory.SetPackageItemExtension(UI_ModalLayer.URL, typeof(UI_ModalLayer));
 }
Esempio n. 23
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(MapCom.URL, typeof(MapCom));
     UIObjectFactory.SetPackageItemExtension(MapBlock1.URL, typeof(MapBlock1));
     UIObjectFactory.SetPackageItemExtension(MapNodeCom.URL, typeof(MapNodeCom));
     UIObjectFactory.SetPackageItemExtension(MapFrame.URL, typeof(MapFrame));
     UIObjectFactory.SetPackageItemExtension(EnemyCom.URL, typeof(EnemyCom));
     UIObjectFactory.SetPackageItemExtension(MapBlock2.URL, typeof(MapBlock2));
 }
Esempio n. 24
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(UI_PupilEquipPanel.URL, typeof(UI_PupilEquipPanel));
     UIObjectFactory.SetPackageItemExtension(UI_TabPupilInfo.URL, typeof(UI_TabPupilInfo));
     UIObjectFactory.SetPackageItemExtension(UI_TabPupilEquip.URL, typeof(UI_TabPupilEquip));
     UIObjectFactory.SetPackageItemExtension(UI_PupilListView.URL, typeof(UI_PupilListView));
     UIObjectFactory.SetPackageItemExtension(UI_PupilListItem.URL, typeof(UI_PupilListItem));
     UIObjectFactory.SetPackageItemExtension(UI_PupilEquipItem.URL, typeof(UI_PupilEquipItem));
     UIObjectFactory.SetPackageItemExtension(UI_PupilView.URL, typeof(UI_PupilView));
 }
Esempio n. 25
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(UI_FightLose.URL, typeof(UI_FightLose));
     UIObjectFactory.SetPackageItemExtension(UI_Character.URL, typeof(UI_Character));
     UIObjectFactory.SetPackageItemExtension(UI_FigthWin.URL, typeof(UI_FigthWin));
     UIObjectFactory.SetPackageItemExtension(UI_FightView.URL, typeof(UI_FightView));
     UIObjectFactory.SetPackageItemExtension(UI_SkillInfo.URL, typeof(UI_SkillInfo));
     UIObjectFactory.SetPackageItemExtension(UI_CharacterInfo.URL, typeof(UI_CharacterInfo));
     UIObjectFactory.SetPackageItemExtension(UI_FightStart.URL, typeof(UI_FightStart));
 }
Esempio n. 26
0
    void Init()
    {
        UIObjectFactory.SetPackageItemExtension("ui://UIMain/GuideLayer", typeof(GuideLayer));
        _guideLayer = (GuideLayer)UIPackage.CreateObject("UIMain", "GuideLayer").asCom;
        _guideLayer.SetSize(GRoot.inst.width, GRoot.inst.height);
        _guideLayer.AddRelation(GRoot.inst, RelationType.Size);
        init = true;

        guidePanel = new GuidePanel();
    }
Esempio n. 27
0
 public static void BindAll()
 {
     UIObjectFactory.SetPackageItemExtension(UI_MainSize.URL, typeof(UI_MainSize));
     UIObjectFactory.SetPackageItemExtension(UI_Card.URL, typeof(UI_Card));
     UIObjectFactory.SetPackageItemExtension(UI_HandCards.URL, typeof(UI_HandCards));
     UIObjectFactory.SetPackageItemExtension(UI_SmallHeroCard.URL, typeof(UI_SmallHeroCard));
     UIObjectFactory.SetPackageItemExtension(UI_Group.URL, typeof(UI_Group));
     UIObjectFactory.SetPackageItemExtension(UI_Main2.URL, typeof(UI_Main2));
     UIObjectFactory.SetPackageItemExtension(UI_PlayerSimpleInfo.URL, typeof(UI_PlayerSimpleInfo));
     UIObjectFactory.SetPackageItemExtension(UI_ChooseHero.URL, typeof(UI_ChooseHero));
 }
Esempio n. 28
0
    void Awake()
    {
        UIPackage.AddPackage("FGUI/main");
        UIObjectFactory.SetPackageItemExtension("ui://main/mailItem", typeof(MailItem));
        //_mainView = this.GetComponent<UIPanel>().ui;

        //_list = _mainView.GetChild("mailList").asList;

        //_list.SetVirtualAndLoop();
        //_list.itemRenderer = RenderListItem;
        //_list.numItems = 50;
    }
Esempio n. 29
0
 public static void SetAllPackageItemExtension()
 {
     UIObjectFactory.SetPackageItemExtension(UI_zhuangjiaList.URL, typeof(UI_zhuangjiaList));
     UIObjectFactory.SetPackageItemExtension(UI_xiafenList.URL, typeof(UI_xiafenList));
     UIObjectFactory.SetPackageItemExtension(UI_main.URL, typeof(UI_main));
     UIObjectFactory.SetPackageItemExtension(UI_Head.URL, typeof(UI_Head));
     UIObjectFactory.SetPackageItemExtension(UI_ludan.URL, typeof(UI_ludan));
     UIObjectFactory.SetPackageItemExtension(UI_LudanItem.URL, typeof(UI_LudanItem));
     UIObjectFactory.SetPackageItemExtension(UI_Settlement.URL, typeof(UI_Settlement));
     UIObjectFactory.SetPackageItemExtension(UI_Alert.URL, typeof(UI_Alert));
     UIObjectFactory.SetPackageItemExtension(UI_SetUI.URL, typeof(UI_SetUI));
     UIObjectFactory.SetPackageItemExtension(UI_InfoMsg.URL, typeof(UI_InfoMsg));
 }
Esempio n. 30
0
        public static void SetPackageItemExtension(string url, System.Type type)
        {

#if USE_HOT

            UIObjectFactory.SetPackageItemExtension(url, () => {
                return appDomain.Instantiate<GComponent>(type.FullName);
            });
#else
            UIObjectFactory.SetPackageItemExtension(url, type);
#endif

        }