Beispiel #1
0
    private void SetupChips(GameWebAPI.RespDataCS_ChipListLogic data)
    {
        int widthLength = 8;

        if (data.userChipList != null)
        {
            GameWebAPI.RespDataCS_ChipListLogic.UserChipList[] dataList = this.GetDataList(data);
            this.chipList = new ChipList(this.partsSortListBase, widthLength, new Vector2(960f, 350f), dataList, true, true);
            this.chipList.SetPosition(new Vector3(-110f, 0f, 0f));
            this.chipList.SetScrollBarPosX(510f);
            this.chipList.SetShortTouchCallback(new Action <GUIListChipParts.Data>(this.OnShortTouchChip));
            this.chipList.SetLongTouchCallback(new Action <GUIListChipParts.Data>(this.OnLongTouchChip));
            this.chipList.AddWidgetDepth(this.partsSortListBase.GetComponent <UIWidget>().depth);
            if (dataList.Length <= 0)
            {
                this.emptyChipLabel.gameObject.SetActive(true);
            }
            else
            {
                this.emptyChipLabel.gameObject.SetActive(false);
            }
        }
        else
        {
            this.emptyChipLabel.gameObject.SetActive(true);
        }
    }
Beispiel #2
0
    public override void Show(Action <int> closeEvent, float sizeX, float sizeY, float showAnimationTime)
    {
        GUICollider.DisableAllCollider("CMD_ChipReinforced");
        RestrictionInput.StartLoad(RestrictionInput.LoadType.LARGE_IMAGE_MASK_ON);
        base.HideDLG();
        GameWebAPI.RespDataCS_ChipListLogic.UserChipList[] array = this.ConvertChipList(ChipDataMng.userChipData);
        this.chipList = new ChipList(this.goEFC_FOOTER, 8, new Vector2(960f, 450f), array, false, true);
        this.chipList.SetPosition(new Vector3(-40f, -70f, 0f));
        this.chipList.SetScrollBarPosX(520f);
        this.chipList.SetShortTouchCallback(new Action <GUIListChipParts.Data>(this.OnShortTouchChip));
        this.chipList.SetLongTouchCallback(new Action <GUIListChipParts.Data>(this.OnLongTouchChip));
        this.chipList.AddWidgetDepth(base.gameObject.GetComponent <UIWidget>().depth);
        base.PartsTitle.SetTitle(StringMaster.GetString("ChipReinforcement-01"));
        this.sortButtonLabel.text      = StringMaster.GetString("SystemSortButton");
        this.sortNameLabel.text        = CMD_ChipSortModal.GetSortName();
        this.sortButton.CallBackClass  = base.gameObject;
        this.sortButton.MethodToInvoke = "OnSortButton";
        this.messageLabel.gameObject.SetActive(array.Count <GameWebAPI.RespDataCS_ChipListLogic.UserChipList>() == 0);
        this.messageLabel.text = StringMaster.GetString("ChipAdministration-01");
        int num = 0;

        if (ChipDataMng.userChipData != null && ChipDataMng.userChipData.userChipList != null)
        {
            num = ChipDataMng.userChipData.userChipList.Length;
        }
        this.listCountLabel.text = string.Format(StringMaster.GetString("SystemFraction"), num, DataMng.Instance().RespDataUS_PlayerInfo.playerInfo.chipLimitMax);
        base.ShowDLG();
        base.SetTutorialAnyTime("anytime_second_tutorial_chip_reinforcement");
        base.Show(closeEvent, sizeX, sizeY, showAnimationTime);
        RestrictionInput.EndLoad();
    }
    public override void Show(Action <int> f, float sizeX, float sizeY, float aT)
    {
        GUICollider.DisableAllCollider("CMD_ChipList");
        RestrictionInput.StartLoad(RestrictionInput.LoadType.LARGE_IMAGE_MASK_ON);
        base.HideDLG();
        this.userChipList = this.ConvertChipList(ChipDataMng.userChipData);
        this.chipList     = new ChipList(this.goEFC_FOOTER, 7, new Vector2(960f, 450f), this.userChipList, false, true);
        this.chipList.SetPosition(new Vector3(-110f, -70f, 0f));
        this.chipList.SetScrollBarPosX(450f);
        this.chipList.SetShortTouchCallback(new Action <GUIListChipParts.Data>(this.OnShortTouchChip));
        this.chipList.SetLongTouchCallback(new Action <GUIListChipParts.Data>(this.OnLongTouchChip));
        this.chipList.AddWidgetDepth(base.gameObject.GetComponent <UIWidget>().depth);
        this.chipList.SetTouchAreaWidth(875f);
        this.messageLabel.gameObject.SetActive(this.userChipList.Length == 0);
        int num = 0;

        if (ChipDataMng.userChipData != null && ChipDataMng.userChipData.userChipList != null)
        {
            num = ChipDataMng.userChipData.userChipList.Length;
        }
        this.listCountLabel.text          = string.Format(StringMaster.GetString("SystemFraction"), num, DataMng.Instance().RespDataUS_PlayerInfo.playerInfo.chipLimitMax);
        this.saleClusterMessageLabel.text = "0";
        this.sortNameLabel.text           = CMD_ChipSortModal.GetSortName();
        this.UpdateCluster();
        this.ChangeViewMode(CMD_ChipAdministration.ViewModeType.List);
        base.ShowDLG();
        base.SetTutorialAnyTime("anytime_second_tutorial_chip_list");
        base.Show(f, sizeX, sizeY, aT);
        RestrictionInput.EndLoad();
    }