Ejemplo n.º 1
0
    public void DoJump(JumpModes mode)
    {
        switch (mode)
        {
        case JumpModes.Die:
            GameManager.Inst.Die();
            break;

        case JumpModes.Jump:
            rigidbody2D.velocity = rigidbody2D.velocity.withY(JumpForce);
            AudioManager.Inst.PlaySound("jump");
            break;
        }
    }
Ejemplo n.º 2
0
 public void SetJumpMode(int mode)
 {
     JumpMode = (JumpModes)mode;
 }