Hi,
I am using this code to move my character in x axis.
moveInput = Input.GetAxis("Horizontal");
Vector3 movement = new Vector3(moveInput, 0, 0);
rb.AddForce(movement * speed,ForceMode.Force);
I know if i use rigidbody velocity the movement will be instantaneous and responsive, however if i use velocity, the players interaction with a projectile (rigidbody) is not giving it a knockback. I want the player to be knocked back when the projectile hits it.
If i use addforce to move the player, this knockback effects works perfectly, but the movement of the character is too slow. How do i make it more responsively. Or is there a way to use velocity to control the player while still retaining that knockback effect? should I not use physics based movement at all? the knockback effect is the most important aspect