Пример #1
0
    public bool ShowTropAction()
    {
        List <StageDC.ScriptDropItem> items = StageDC.GetStageScriptDrops();

        if ((m_lRewardInfo != null && m_lRewardInfo.Count > 0) || items.Count > 0)
        {
            TrophiesActionWnd TropWnd = WndManager.GetDialog <TrophiesActionWnd>();
            if (TropWnd)
            {
                TropWnd.ClearTropiesData();
                TropWnd.AddTropiesData(m_lRewardInfo);
                //List<StageDC.ScriptDropItem> items = StageDC.GetStageScriptDrops();
                foreach (StageDC.ScriptDropItem item in items)
                {
                    ItemUIInterface.ItemIconInfo iconInfo = ItemUIInterface.GetIconInfo((ItemUIInterface.IconType)item.mType, item.mID, item.mIsSoul, item.mIsBook);
                    iconInfo.mCount = item.mCount;
                    TropWnd.AddTropiesData(iconInfo.mName, (int)iconInfo.mType, iconInfo.mID, iconInfo.mIsSoul, iconInfo.mIsBook, true, item.mCount);
                }
                TropWnd.SetWndType(3);
                TropWnd.GetTropies(1, ShowStageResult);
                TropWnd.MyHead.LblDes.gameObject.SetActive(false);
                TropWnd.FinalEventClikHandler += BackMainScence;
                return(true);
            }
        }
        return(false);
    }
Пример #2
0
    private void BuildSummonResponse(int nErrorCode)
    {
        if (nErrorCode == 0 && m_iWndType == 2)
        {
            GameObjectActionExcute gae       = GameObjectActionExcute.CreateExcute(gameObject);
            s_itemtypeInfo         info      = new s_itemtypeInfo();
            s_building_typeInfo    buildInfo = buildingM.GetBuildType(m_buildInfo.BuildType);
            if (buildInfo != null && buildInfo.name != null)
            {
                info.name = buildInfo.name;
            }
            info.gtype = 3;//item.ErnieRewardType;//如果是碎片该类型也是1.
            info.gid   = m_buildInfo.BuildType;

            if (info == null)
            {
#if UNITY_EDITOR_LOG
                NGUIUtil.DebugLog("SoldierSummonResponse soldTypeId get s_itemtypeInfo is null" + soldTypeId.ToString());
#endif

                return;
            }
            List <s_itemtypeInfo> l = new List <s_itemtypeInfo>();
            l.Add(info);

            TrophiesActionWnd TropWnd = WndManager.GetDialog <TrophiesActionWnd>();
            if (TropWnd)
            {
                TropWnd.ClearTropiesData();
                TropWnd.AddTropiesData(l);
                TropWnd.SetWndType(4);
                TropWnd.MyHead.LblDes.gameObject.SetActive(false);
            }

            WndManager.DestoryDialog <SummonHeroWnd>();
        }
    }
Пример #3
0
    private void SoldierSummonResponse(int nErrorCode)
    {
        if (nErrorCode == 0 && m_iWndType == 1)
        {
            GameObjectActionExcute gae      = GameObjectActionExcute.CreateExcute(gameObject);
            s_itemtypeInfo         info     = new s_itemtypeInfo();
            s_soldier_typeInfo     TypeInfo = SoldierM.GetSoldierType(m_soldierInfo.SoldierTypeID);
            if (TypeInfo != null)
            {
                info.name = TypeInfo.name;
            }
            info.gtype = 1;
            info.gid   = m_soldierInfo.SoldierTypeID;

            if (info == null)
            {
#if UNITY_EDITOR_LOG
                NGUIUtil.DebugLog("SoldierSummonResponse soldTypeId get s_itemtypeInfo is null" + soldTypeId.ToString());
#endif

                return;
            }
            List <s_itemtypeInfo> l = new List <s_itemtypeInfo>();
            l.Add(info);

            TrophiesActionWnd TropWnd = WndManager.GetDialog <TrophiesActionWnd>();
            if (TropWnd)
            {
                TropWnd.ClearTropiesData();
                TropWnd.AddTropiesData(l);
                TropWnd.SetWndType(3);
                TropWnd.MyHead.LblDes.gameObject.SetActive(false);
            }

            WndManager.DestoryDialog <SummonHeroWnd>();
        }
    }
Пример #4
0
    /// <summary>
    /// 显示船只设计图
    /// </summary>
    public void ShowDesignAction()
    {
        treasure.TreasureRobSettleResponse response = null;
        if (response != null)
        {
            int sShipCanvasID      = response.shipdrawingid;
            StaticShipCanvas sInfo = ShipPlanM.GetShipCanvasInfo(sShipCanvasID);
            if (sInfo != null)
            {
                sdata.s_itemtypeInfo itypeInfo = new sdata.s_itemtypeInfo();
                itypeInfo.gid   = sShipCanvasID;
                itypeInfo.name  = sInfo.Name;
                itypeInfo.gtype = 5;
                List <sdata.s_itemtypeInfo> lInfo = new List <sdata.s_itemtypeInfo>();
                lInfo.Add(itypeInfo);

                TrophiesActionWnd TropWnd = WndManager.GetDialog <TrophiesActionWnd>();
                if (TropWnd)
                {
                    TropWnd.ClearTropiesData();
                    TropWnd.AddTropiesData(lInfo);
                    TropWnd.SetWndType(5);
                    TropWnd.MyHead.LblDes.gameObject.SetActive(false);
                    TropWnd.BtnOKClickHandler += CheckShowCombatResult;
                }
            }
            else
            {
                CheckShowCombatResult();
            }
        }
        else
        {
            CheckShowCombatResult();
        }
    }
Пример #5
0
    /// <summary>
    /// 显示首次获得黑科技表现
    /// </summary>
    private void ShowTrophiesAction()
    {
        if (CurSummonCaptianID == 0)
        {
            return;
        }

        CaptionInfo cInfo = new CaptionInfo();

        GodSkillM.GetCaption(CurSummonCaptianID, ref cInfo);
        GodSkillInfo gInfo = new GodSkillInfo();

        //黑科技抽取是1级,王振鑫确认
        GodSkillM.GetGodSkill(cInfo.m_godskilltype1, 1, ref gInfo);
        string name = "";

        name = gInfo.m_name;
        sdata.s_itemtypeInfo itypeInfo = new sdata.s_itemtypeInfo();
        itypeInfo.gid   = CurSummonCaptianID;
        itypeInfo.name  = name;
        itypeInfo.gtype = 3;

        List <sdata.s_itemtypeInfo> lInfo = new List <sdata.s_itemtypeInfo>();

        lInfo.Add(itypeInfo);

        TrophiesActionWnd TropWnd = WndManager.GetDialog <TrophiesActionWnd>();

        if (TropWnd)
        {
            TropWnd.ClearTropiesData();
            TropWnd.AddTropiesData(lInfo);
            TropWnd.SetWndType(3);
            TropWnd.MyHead.LblDes.gameObject.SetActive(false);
        }
    }