Example #1
0
    /// <summary>
    /// 黑科技
    /// </summary>
    void BtnBlackScience_OnClickEventHandler(UIButton sender)
    {
        if (BlackScienceDC.CheckHaveCaption() == false)
        {
            NGUIUtil.ShowTipWndByKey(30000050);
            return;
        }
        BlackScienceChoWnd bsWnd       = WndManager.GetDialog <BlackScienceChoWnd>();
        ShipPlan           P           = ShipPlanDC.GetCurShipPlan();
        CaptionInfo        captionInfo = BlackScienceDC.GetCaptionD(P.BlackScienceID);

        bsWnd.SetSelectCaptain(captionInfo);
    }
Example #2
0
    // 传的是数据表里的ID
    public void SetBlackScienceDataID(int id)
    {
        CaptionInfo c = BlackScienceDC.GetCaptionD(id);

        m_SelectedBlackScienceDataID    = id;
        m_SelectedBlackScienceCaptainID = c.m_captionid;
        if (c != null)
        {
            NGUIUtil.Set2DSprite(MyHead.SprCaptainHead, "Textures/role/", c.m_captionid.ToString());
        }
        else
        {
            NGUIUtil.DebugLog("BlackScienceID = " + id + " 未设置");
        }
    }
Example #3
0
    void RefreshBlackScienceUI()
    {
        ShipPlan    P           = ShipPlanDC.GetCurShipPlan();
        CaptionInfo captionInfo = BlackScienceDC.GetCaptionD(P.BlackScienceID);

        if (captionInfo != null)
        {
            SetBlackScienceUI(captionInfo);
        }
        else     //未设置黑科技
        {
            NGUIUtil.Set2DSprite(MyHead.SprCaptainHead, "Textures/role/", "-999");
            NGUIUtil.SetLableText <string>(MyHead.LblSkillName, "");
        }
    }