Ejemplo n.º 1
0
 public void checkToStand(Animator animator, Controller controller, AnimatorHashCodes animatorHashCodes)
 {
     if (!controller.drop)
     {
         animator.SetBool(animatorHashCodes.dropping, false);
     }
 }
Ejemplo n.º 2
0
 public void checkToDrop(Animator animator, Controller controller, AnimatorHashCodes animatorHashCodes)
 {
     if (controller.drop)
     {
         animator.SetBool(animatorHashCodes.dropping, true);
     }
 }
Ejemplo n.º 3
0
 public void checkToIdle(Animator animator, Controller controller, AnimatorHashCodes animatorHashCodes)
 {
     // checks to see if movement has/is stopped
     if (!controller.moveRight ^ controller.moveLeft)
     {
         animator.SetBool(animatorHashCodes.moving, false);
     }
 }
Ejemplo n.º 4
0
 public void checkToFall(Animator animator, Controller controller, AnimatorHashCodes animatorHashCodes)
 {
     // checks for upward/rise/jump input
     if (!controller.localPhysicsEngine.localCollisionManager.collisionData.bottomCollision)
     {
         animator.SetBool(animatorHashCodes.collidedDown, false);
     }
 }
Ejemplo n.º 5
0
 public void checkToJump(Animator animator, Controller controller, AnimatorHashCodes animatorHashCodes)
 {
     // checks for upward/rise/jump input
     if (controller.rise)
     {
         animator.SetBool(animatorHashCodes.jumping, true);
     }
 }
Ejemplo n.º 6
0
 // accessible functions for all States
 public void checkToMove(Animator animator, Controller controller, AnimatorHashCodes animatorHashCodes)
 {
     // checks for movement input
     if (controller.moveRight ^ controller.moveLeft)
     {
         animator.SetBool(animatorHashCodes.moving, true);
     }
 }
Ejemplo n.º 7
0
 public AnimatorHashCodes getAnimatorHashCodes()
 {
     if (animatorHashCodes == null)
     {
         animatorHashCodes = GameObject.Find("HashCodes").GetComponent <AnimatorHashCodes>();
     }
     return(animatorHashCodes);
 }
Ejemplo n.º 8
0
        public void start()
        {
            getLocalPhysicsEngine();
            animator = getAnimator();
            animatorHashCodes = GameObject.FindObjectOfType<AnimatorHashCodes>();

            localPhysicsEngine.JumpStart_Event += JumpStart;
            localPhysicsEngine.HitTop_Event += HitTop;
            localPhysicsEngine.HitBottom_Event += HitBottom;
            localPhysicsEngine.HitRight_Event += HitRight;
            localPhysicsEngine.HitLeft_Event += HitLeft;
        }
Ejemplo n.º 9
0
 public void checkToDrop(Animator animator, Controller controller, AnimatorHashCodes animatorHashCodes)
 {
     Debug.Log("Im an empty function:)");
 }
Ejemplo n.º 10
0
 public void start()
 {
     getLocalPhysicsEngine();
     animator          = getAnimator();
     animatorHashCodes = GameObject.FindObjectOfType <AnimatorHashCodes>();
 }