Exemplo n.º 1
0
    public void ClickOK(IUIObject obj)
    {
        NrMyCharInfo kMyCharInfo = NrTSingleton <NkCharManager> .Instance.m_kMyCharInfo;

        if (kMyCharInfo == null)
        {
            return;
        }
        string text = this.m_tfText.Text;

        PlayerPrefs.SetString(NrPrefsKey.NEWGUILD_INVITE_ADVERTISING, text);
        string first   = NrLinkText.GuildName(NrTSingleton <NewGuildManager> .Instance.GetGuildName());
        string @string = NrTSingleton <UIDataManager> .Instance.GetString(first, text);

        NrTSingleton <ChatManager> .Instance.SendMessage(CHAT_TYPE.NORMAL, @string, false, null, 0, 0L, 0);

        NrTSingleton <ChatManager> .Instance.MakeChatText(NrTSingleton <FormsManager> .Instance.GetForm(G_ID.CHAT_MOBILE_SUB_DLG), CHAT_TYPE.NORMAL, kMyCharInfo.ColosseumGrade, @string, null);

        Main_UI_SystemMessage.ADDMessage(NrTSingleton <NrTextMgr> .Instance.GetTextFromNotify("866"), SYSTEM_MESSAGE_TYPE.NORMAL_MESSAGE);
        NrTSingleton <NewGuildManager> .Instance.ClearDlg();
    }
Exemplo n.º 2
0
    public void ClickOK(IUIObject obj)
    {
        if (string.Empty.Equals(this.m_tfInput.Text))
        {
            Main_UI_SystemMessage.ADDMessage(NrTSingleton <NrTextMgr> .Instance.GetTextFromMessageBox("85"), SYSTEM_MESSAGE_TYPE.IMPORTANT_MESSAGE);
            return;
        }
        if (this.m_eType == CouponDlg.TYPE.SEND_SERVER)
        {
            GS_COUPON_USE_REQ gS_COUPON_USE_REQ = new GS_COUPON_USE_REQ();
            TKString.StringChar(this.m_tfInput.Text, ref gS_COUPON_USE_REQ.strCouponCode);
            SendPacket.GetInstance().SendObject(1648, gS_COUPON_USE_REQ);
        }
        else
        {
            StoryChatSetDlg storyChatSetDlg = NrTSingleton <FormsManager> .Instance.GetForm(G_ID.STORYCHAT_SET_DLG) as StoryChatSetDlg;

            if (storyChatSetDlg != null)
            {
                storyChatSetDlg.SetInputText(NrLinkText.CouponName(this.m_tfInput.Text));
            }
        }
        NrTSingleton <FormsManager> .Instance.CloseForm(G_ID.COUPON_DLG);
    }
Exemplo n.º 3
0
    public void ClickShare(IUIObject obj)
    {
        if (0L >= this.m_nReplayUnique || 0 >= this.m_nType)
        {
            return;
        }
        if (this.m_kShareChat.StateNum == 0 && this.m_kShareStoryChat.StateNum == 0)
        {
            return;
        }
        string text = string.Empty;

        if (this.m_nType == 1)
        {
            text = NrLinkText.PlunDerReplayName(this.m_nReplayUnique);
        }
        else if (this.m_nType == 2)
        {
            text = NrLinkText.ColosseumReplayName(this.m_nReplayUnique);
        }
        else if (this.m_nType == 3)
        {
            text = NrLinkText.InfiBattleReplayName(this.m_nReplayUnique);
        }
        else if (this.m_nType == 4)
        {
            text = NrLinkText.MineReplayName(this.m_nReplayUnique);
        }
        if (string.Empty == text)
        {
            return;
        }
        if (this.m_kShareChat.StateNum == 1)
        {
            ChatMobile_Sub_Dlg chatMobile_Sub_Dlg = NrTSingleton <FormsManager> .Instance.LoadForm(G_ID.CHAT_MOBILE_SUB_DLG) as ChatMobile_Sub_Dlg;

            if (chatMobile_Sub_Dlg != null)
            {
                chatMobile_Sub_Dlg.Show();
                chatMobile_Sub_Dlg.SetInputText(text);
            }
        }
        if (this.m_kShareStoryChat.StateNum == 1)
        {
            NrTSingleton <FormsManager> .Instance.LoadForm(G_ID.STORYCHAT_DLG);

            StoryChatSetDlg storyChatSetDlg = NrTSingleton <FormsManager> .Instance.LoadForm(G_ID.STORYCHAT_SET_DLG) as StoryChatSetDlg;

            if (storyChatSetDlg != null)
            {
                storyChatSetDlg.SetInputText(text);
            }
        }
        NrTSingleton <FormsManager> .Instance.CloseForm(G_ID.PLUNDERMAIN_DLG);

        NrTSingleton <FormsManager> .Instance.CloseForm(G_ID.PLUNDERRECORD_DLG);

        NrTSingleton <FormsManager> .Instance.CloseForm(G_ID.COLOSSEUMMAIN_DLG);

        this.Close();
    }