using FSM; using UnityEngine; using ZXKFramework; namespace DongWuYiXue.DaoNiaoShu { public class QingJieBaoPiKouState : FsmState { Coroutine cor; public override void OnStateEnter() { base.OnStateEnter(); this.Log("进入清洁包皮口及周围皮肤状态"); fsm.ShowCamera("清洁包皮口1_Camera"); fsm.Light_EnableInteraction("氯己定棉球"); fsm.ShowArrow("点击氯己定棉球", "氯己定棉球"); fsm.ShowTip(0); fsm.PlayBgm(0); fsm.InteractionDown("氯己定棉球", c => { if (fsm.main_gameModel.modeType == ModeType.ShiXun) { fsm.AddScore(4, 0); } fsm.HideArrow(); fsm.ShowCamera("清洁包皮口2_Camera"); fsm.Unlight_DisableInteraction("氯己定棉球"); fsm.ShowTip(1); fsm.PlayBgm(1); fsm.Show("手拿镊子消毒"); cor = Game.Instance.IEnumeratorManager.Run(3.0f, () => { if (fsm.main_gameModel.modeType == ModeType.ShiXun) { fsm.AddScore(5, 1); } fsm.nextState = true; }); }); } public override void OnStateStay() { base.OnStateStay(); } public override void OnStateExit() { base.OnStateExit(); if (null != cor) { Game.Instance.IEnumeratorManager.Stop(cor); cor = null; } fsm.HideArrow(); fsm.Hide("手拿镊子消毒"); fsm.Unlight_DisableInteraction("氯己定棉球"); fsm.nextState = false; } } }