Exemplo n.º 1
0
 // Start is called before the first frame update
 void Start()
 {
     sun             = GameObject.Find("Sun");
     camera          = GetComponent <Camera>();
     tapController   = GameObject.Find("Controller").GetComponent <TapController>();
     pinchController = GameObject.Find("Controller").GetComponent <PinchController>();
     swipeController = GameObject.Find("Controller").GetComponent <SwipesController>();
 }
Exemplo n.º 2
0
 public void Permit(bool aroundOnly = false)
 {
     isAroundOnlyPermited = aroundOnly;
     if (!isPermited)
     {
         swipeController        = GameObject.Find("Controller").GetComponent <SwipesController>();
         twistController        = GameObject.Find("Controller").GetComponent <TwistController>();
         isPermited             = true;
         swipeDownSubscription  = swipeController.SubscribeToSwipe(SwipesController.Swipe.Down, _SwipeHandler);
         swipeLeftSubscription  = swipeController.SubscribeToSwipe(SwipesController.Swipe.Left, _SwipeHandler);
         swipeRightSubscription = swipeController.SubscribeToSwipe(SwipesController.Swipe.Right, _SwipeHandler);
         swipeUpSubscription    = swipeController.SubscribeToSwipe(SwipesController.Swipe.Up, _SwipeHandler);
         twistSubscription      = twistController.SubscribeToTwist(TwistController.Twist.Twist, _TwistHandler);
     }
 }
Exemplo n.º 3
0
    // Start is called before the first frame update
    void Start()
    {
        currentStage       = Stages.WaitingForStart;
        tutorialSwipeDown  = GameObject.Find("SwipeDownGesture");
        tutorialSwipeUp    = GameObject.Find("SwipeUpGesture");
        tutorialSwipeLeft  = GameObject.Find("SwipeLeftGesture");
        tutorialSwipeRight = GameObject.Find("SwipeRightGesture");

        swipesController = GameObject.Find("Controller").GetComponent <SwipesController>();

        tutorialSwipeDown.SetActive(false);
        tutorialSwipeUp.SetActive(false);
        tutorialSwipeLeft.SetActive(false);
        tutorialSwipeRight.SetActive(false);
    }