#Character Controller Tutorial
1 messages · Page 1 of 1 (latest)
okay 🙂 thanks
basically the ``` if (!myCharacterController.isGrounded || myspeedY < -10)
{
myspeedY += (mGravity * Time.deltaTime);
}
else
{
myspeedY = 0;
}
or Visual Studio
no 0 errors
|| myspeedY < -10
when is this in the tutorial?
it is more about the logic
that's something i am testing now
to force it
i removed the isGrounded and it works
but I am still above the ground without rigidbody so I don;'t know how to give the character gravit5y without the rigid body
well - take a minute to think about this
The character controller is scripting gravity
While Rigidbody uses the built-in Physics system, that does the calculations for you.
You are Not making a Rigidbody Controller right now
so if Rigidbody is what you want, you need a different tutorial
Anyway
post me your current code
Line 43
Vector3 mymoveDirection = new Vector3(Input.GetAxis("Horizontal"), 0.0f, Input.GetAxis("Vertical")).normalized;
You can use GetAxisRaw instead of normalizing the vector
Thank you, I ll try to read something about it and thinking it through I guess is fairly easy logic issue here ^^ but I am kind of sleepy. Tomorrow I ll reply here a solution :))