Пример #1
0
 public void RemoveMail(MailInfo info)
 {
     for (int i = 0; i < m_mailList.Count; ++i)
     {
         if (m_mailList[i] == info)
         {
             GameEvent.instance.OnEventRemoveMail(info);
             m_mailList.RemoveAt(i);
             break;
         }
     }
 }
Пример #2
0
        public void Init(MailInfo info)
        {
            m_titleText = transform.Find("Title").GetComponent <Text>();
            m_dateText  = transform.Find("Date").GetComponent <Text>();

            m_info = info;

            m_titleText.text = m_info.Name;
            m_dateText.text  = System.DateTime.Now.ToString("MM-dd");

            transform.Find("Background").GetComponent <Button>().onClick.AddListener(OnButtonUp);
        }
Пример #3
0
 void OnEventRemoveMail(MailInfo info)
 {
     for (int i = 0; i < m_slotList.Count; ++i)
     {
         if (m_slotList[i].info == info)
         {
             Destroy(m_slotList[i].gameObject);
             m_slotList.RemoveAt(i);
             break;
         }
     }
 }
Пример #4
0
        void OnEventPlayDialog(NPC npc)
        {
            m_isSucceeded = true;
            GameEvent.instance.EventPlayDialog -= OnEventPlayDialog;
            GameEvent.instance.OnEventNotice("퀘스트 : " + m_data.Name + " 성공!", 3f, false);

            //TODO 서버가 없어서 우선 테스트 용으로 처리
            MailInfo mail = new MailInfo();

            mail.Name         = "katana";
            mail.Description  = "Item Katana";
            mail.RewardItemID = 0;
            Mail.instance.AddMail(mail);
            //GameEvent.instance.OnEventArriveMail(mail);
        }
Пример #5
0
 public void AddMail(MailInfo info)
 {
     GameEvent.instance.OnEventArriveMail(info);
     m_mailList.Add(info);
 }
Пример #6
0
 void OnEventArriveMail(MailInfo mailInfo)
 {
     m_mailRedDotImage.gameObject.SetActive(true);
 }
Пример #7
0
 public void OnEventRemoveMail(MailInfo info)
 {
     EventRemoveMail?.Invoke(info);
 }
Пример #8
0
 public void OnEventArriveMail(MailInfo info)
 {
     EventArriveMail?.Invoke(info);
 }