2025-09-19 17:28:05 +08:00

65 lines
2.0 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using FSM;
using ZXKFramework;
namespace YiLiao.JingMaiLiuZhiZhen
{
public class HeDuiYiZhuState : FsmState<FSMManager>
{
public override void OnStateEnter()
{
base.OnStateEnter();
fsm.ShowCamera("HeDuiYiZhuState_Camera");
fsm.ShowTip(0);
fsm.PlayBgm(0);
fsm.Light_EnableInteraction("长期医嘱单");
fsm.ShowArrow("请点击长期医嘱单", "长期医嘱单",0,0);
fsm.ShowTipBtn(() => {
fsm.Light_EnableInteraction("长期医嘱单", true);
fsm.ShowArrow("请点击长期医嘱单", "长期医嘱单", 0, 0, 5, true);
},0);
fsm.InteractionDown("长期医嘱单", args => {
fsm.HideTipBtn();
fsm.HideArrow();
fsm.AddScore(1, 1);
fsm.ShowTip(1);
fsm.PlayBgm(1);
fsm.Unlight_DisableInteraction("长期医嘱单");
fsm.InteractionDown("长期医嘱单", null);
fsm.PlayClip("核对医嘱", () => {
fsm.ShowCamera("HeDuiYiZhuState_Camera2");
fsm.ShowSpeakPanel(new UnityEngine.Vector3(400, 100),
"请核对医嘱0.9%氯化钠注射液 (开放/维持静脉通路)100ml ivgtt st床号1姓名王丽。",
"姓名王丽", 1, 0, SpeakAction);
});
});
}
void SpeakAction(int args1, string callBackTxt)
{
if (args1 == 1)
{
fsm.AddScore(2, 2);
}
else if (args1 == 0)
{
fsm.AddScore(0, 2);
}
else
{
Game.Instance.eventManager.Raise(new PlayTrueOrFalseEvent() { isTrue = true });
}
fsm.PlayClip("核对医嘱2", () => {
fsm.nextState = true;
});
}
public override void OnStateExit()
{
base.OnStateExit();
fsm.PlayClip("核对医嘱Reset");
fsm.nextState = false;
}
}
}