示例#1
0
 public override void ShowCurrentDialog()
 {
     if (dialogIndex < dialogList.Count)
     {
         DialogContent c = dialogList[dialogIndex];
         talkerText.text  = "" + c.talker + ": ";
         contentText.text = "  " + c.content + "    ";
         if (noticeText.text == "")
         {
             noticeText.Hide();
         }
         if (c.talker == "")
         {
             talkerText.Hide();
         }
         if (c.isPlayer)
         {
             transform.position = playerPos;
         }
         else
         {
             transform.position = npcPos;
         }
         Open();
     }
     else
     {
         Clear();
     }
 }
示例#2
0
        public virtual void ShowCurrentDialog()
        {
            if (dialogIndex < dialogList.Count)
            {
                if (IsTyping())
                {
                    contentText.ShowFullContent();
                    return;
                }

                currentDialog = dialogList[dialogIndex];
                string contentStr = prefix + currentDialog.content;
                JudgeContentSize(contentStr);

                talkerText.text = currentDialog.talker + ": \r\n";
                contentText.TypingFX(contentStr, 0.048f);
                if (noticeText.text == "")
                {
                    noticeText.Hide();
                }
                if (currentDialog.talker == "")
                {
                    talkerText.Hide();
                }

                Open();
            }
            else
            {
                Clear();
            }
        }
示例#3
0
 public void AddContent(DialogContent dialogContent)
 {
     contentList.Add(dialogContent);
 }
示例#4
0
 public void AddContent(DialogContent content)
 {
     dialogList.Add(content);
 }