public override void OnEnter()
        {
            int v = GameRunDataHolder.GetType(dataName.Value);

            if (v == compareValue.Value)
            {
                Fsm.Event(equalEvent);
            }
            else
            {
                Fsm.Event(notEqualEvent);
            }
            Finish();
        }
Esempio n. 2
0
        public override void OnEnter()
        {
            bool v = GameRunDataHolder.GetFlag(flagName.Value);

            if (v)
            {
                Fsm.Event(trueEvent);
            }
            else
            {
                Fsm.Event(falseEvent);
            }
            Finish();
        }
Esempio n. 3
0
    void OnGloveConnected()
    {
        GameRunDataHolder.SetType("InteractingSource", (int)InteractingSource.VRGlove);
        Teleporter teleporter = GetComponent <Teleporter>();

        if (teleporter != null && model != null)
        {
            teleporter.LineDrawer.emittingPoint = model.finger;
        }

        VRInteractor interactor = GetComponent <VRInteractor>();

        if (interactor != null && model != null)
        {
            interactor.acquirePoint = model.finger;
            transform.Find("Contactor").gameObject.SetActive(false);
        }
    }
Esempio n. 4
0
    IEnumerator CheckVRDeviceRoutine()
    {
        if (playMode == PlayMode.Auto)
        {
            yield return(new WaitForSeconds(0.8f));

            if (!IsVRReadyAndConnected())
            {
                isUsingSimulator = true;
                Destroy(VRBodyRig.gameObject);
                GlobalEventManager.SendEvent("VRPlayer.PCBodyReady");
                GameRunDataHolder.SetType("InteractingSource", (int)InteractingSource.Mouse);
            }
            else
            {
                isUsingSimulator = false;
                Destroy(PCSimulatorRig.gameObject);
                GlobalEventManager.SendEvent("VRPlayer.VRBodyReady");
                GameRunDataHolder.SetType("InteractingSource", (int)InteractingSource.VRJoystick);
            }
        }
        else if (playMode == PlayMode.PCSimulator)
        {
            isUsingSimulator = true;
            Destroy(VRBodyRig.gameObject);
            GlobalEventManager.SendEvent("VRPlayer.PCBodyReady");
            GameRunDataHolder.SetType("InteractingSource", (int)InteractingSource.Mouse);
        }
        else
        {
            isUsingSimulator = false;
            Destroy(PCSimulatorRig.gameObject);
            GlobalEventManager.SendEvent("VRPlayer.VRBodyReady");
            GameRunDataHolder.SetType("InteractingSource", (int)InteractingSource.VRJoystick);
        }
    }
Esempio n. 5
0
 public override void OnEnter()
 {
     GameRunDataHolder.SetType(dataName.Value, value.Value);
     Finish();
 }
 public override void OnEnter()
 {
     GameRunDataHolder.SetFlag(flagName.Value, value.Value);
     Finish();
 }