예제 #1
0
 /// <summary>
 /// Changes character velocities when smashing, and sets the smashing state to true, if possible.
 /// </summary>
 public void OnSmashInputDown()
 {
     if (!controller.collisions.below && elementController.getElement().Equals("Earth"))
     {
         velocity.x = 0f;
         isSmashing = true;
         GetComponent <PlayerInput>().hasControl = false;
         StartCoroutine(SmashAnimation());
     }
 }