47 lines
1.4 KiB
C#
47 lines
1.4 KiB
C#
using FSM;
|
|
using System;
|
|
using System.Buffers;
|
|
using ZXKFramework;
|
|
namespace YiLiao.JingMaiLiuZhiZhen
|
|
{
|
|
public class JieShiState : FsmState<FSMManager>
|
|
{
|
|
public override void OnStateEnter()
|
|
{
|
|
base.OnStateEnter();
|
|
fsm.ShowCamera("JieShiState_Camera");
|
|
fsm.PlayBgm(0);
|
|
fsm.ShowTip(0);
|
|
fsm.PlayClip("解释");
|
|
fsm.ShowSpeakPanel(new UnityEngine.Vector3(-220, 222),
|
|
"您好,王丽。一会需要给您扎一个留置针,最主要目的是建立一个给药的通道,这样等医生开的药配好后,就可以直接接过来输注。这个管子可以在血管里安全保留几天,避免反复穿刺,扎针进去的那一下,有一点刺痛感,您别太担心。我们会尽量轻一点。",
|
|
"保留几天", 2, 1, SpeakAction);
|
|
}
|
|
|
|
private void SpeakAction(int args1, string arg2)
|
|
{
|
|
if (args1 == 1)
|
|
{
|
|
fsm.AddScore(2, 1);
|
|
}
|
|
else if (args1 == 0)
|
|
{
|
|
fsm.AddScore(0, 1);
|
|
}
|
|
else
|
|
{
|
|
Game.Instance.eventManager.Raise(new PlayTrueOrFalseEvent() { isTrue = true });
|
|
}
|
|
fsm.PlayClip("解释2", () => {
|
|
fsm.nextState = true;
|
|
});
|
|
}
|
|
|
|
public override void OnStateExit()
|
|
{
|
|
base.OnStateExit();
|
|
fsm.nextState = false;
|
|
}
|
|
}
|
|
}
|