I think the player should jump inclined top. But actually he jumped randomly. Is there anything wrong?private void JumpAndTurn()
{
AddForce(m_Transform.forward * (-1 * 25) + m_Transform.up * 60);
m_CharacterLocomotion.Torque = Quaternion.Euler(new Vector3(0, 180, 0));
}
Invoke in Update()
public override void Update()
{
base.Update();
if (CanStartAbility() == false)
{
StopAbility(true);
}
if (_playerInput.GetButtonDown("Jump"))
{
_animator.SetTrigger(CustomTrigger1);
JumpAndTurn();
StopAbility(true);
}
}
Last edited: