49 lines
1.6 KiB
C#
49 lines
1.6 KiB
C#
using FSM;
|
|
namespace YiLiao.XinFeiTingZhen
|
|
{
|
|
public class JianJiaGu : FsmState<FSMManager>
|
|
{
|
|
public override void OnStateEnter()
|
|
{
|
|
base.OnStateEnter();
|
|
fsm.ShowTip(0);
|
|
fsm.PlayBgm(0);
|
|
|
|
GameManager.Instance.multiObjectController.RotateAllTo180(() => {
|
|
fsm.ShowArrow("点击“肩胛骨”", "肩胛骨左", 0, 999);
|
|
fsm.Light_EnableInteraction("肩胛骨左");
|
|
fsm.Light_EnableInteraction("肩胛骨右");
|
|
});
|
|
|
|
fsm.InteractionDown("肩胛骨左", args => {
|
|
fsm.AddScore(0, 0.5f);
|
|
fsm.Unlight_DisableInteraction("肩胛骨左");
|
|
fsm.Unlight_DisableInteraction("肩胛骨右");
|
|
fsm.InteractionDown("肩胛骨左", null);
|
|
fsm.InteractionDown("肩胛骨右", null);
|
|
fsm.HideArrow();
|
|
fsm.PlayClip("肩胛骨动画", () => {
|
|
fsm.nextState = true;
|
|
});
|
|
});
|
|
fsm.InteractionDown("肩胛骨右", args => {
|
|
fsm.AddScore(0, 0.5f);
|
|
fsm.Unlight_DisableInteraction("肩胛骨右");
|
|
fsm.Unlight_DisableInteraction("肩胛骨左");
|
|
fsm.InteractionDown("肩胛骨右", null);
|
|
fsm.InteractionDown("肩胛骨左", null);
|
|
fsm.HideArrow();
|
|
fsm.PlayClip("肩胛骨动画", () => {
|
|
fsm.nextState = true;
|
|
});
|
|
});
|
|
}
|
|
|
|
public override void OnStateExit()
|
|
{
|
|
base.OnStateExit();
|
|
fsm.nextState = false;
|
|
}
|
|
}
|
|
}
|