I have a project here, a school project, and I transferred the script from the first person movement tutorial into it, but the script only removes the mouse. No camera movement, no WASD controls, nothing. The project is here.
If you debug through the code, you see that âpowerâ and âlookSpeedâ are null
You need to parse the script in the editor so you can change the attribute values:
I changed those variables, and re enabled physics, but turned gravity off, and now, when I face a direction and press the W key, it just keeps going, no way to stop. This is space, so no gravity. Any idea how to fix?
Well⌠How would you stop yourself in space?..
Good point. Here, lemme implement âartificial gravityâ.
Any idea how I can get the capsule to quit rolling?
You can lock rotational movement of a rigid body by setting âAngular Factorâ to zero in one or more axes.
The player is still falling out of the spaceship. Is this actually correct?
That will correctly lock rotation, yes. Whether that body will collide correctly against other bodies will depend on how youâve also set up the collision component, and the rigidbody+collision components of other bodies in your scene.
Imma change it to a cube collision.