npc对话

This commit is contained in:
陈向学 2024-09-02 19:10:22 +08:00
parent 42648d474e
commit 17edf664b7
2 changed files with 13 additions and 2 deletions

View File

@ -139,18 +139,28 @@ public class StepState_1002 : StepState
SiteManager.instance.measuringCabinet.Init();
//还原npc对话
GameObject.FindObjectsOfType<NPCController>().ToList().ForEach(a => { a.speackIndex = 0; });
GameObject.FindObjectsOfType<NPCController>().ToList().ForEach(a =>
{
a.speackIndex = 0;
a.spriteRenderer.gameObject.SetActive(true);
});
}
else if (num == 8)
{
//班前会
GameObject.FindObjectsOfType<NPCController>().ToList().Find(a => a.triggerName == "NPC¿Í»§").spriteRenderer.gameObject.SetActive(false);
}
else if (num == 9)
{
//接线检查
//还原npc负责人
GameObject.FindObjectsOfType<NPCController>().ToList().Find(a => a.triggerName == "NPC负责人").speackIndex = 1;
GameObject.FindObjectsOfType<NPCController>().ToList().ForEach(a =>
{
if(a.triggerName == "NPC¸ºÔðÈË")
a.speackIndex = 1;
a.spriteRenderer.gameObject.SetActive(false);
});
}
else if(num == 10)
{

View File

@ -18,6 +18,7 @@ public class UI_CustomSessionPanel : BasePanel
{
this.triggerID = triggerID;
callBack += _callBack;
GetControl<TextMeshProUGUI>("ClientText_DialogBox").DOKill();
GetControl<TextMeshProUGUI>("ClientText_DialogBox").text = "";
//UItext = GetControl<TextMeshProUGUI>("ClientText_DialogBox");
StartTypewriterEffect(clientTalk);