Create Player

Aurora FPS has the ability to create player based on CharacterController or Rigidbody.

Player based on Character Controller

Traditional first-person control in the style of Doom is not realistic, from the point of view of physics. The character runs at 90 miles per hour, stops instantly and turns in a matter of moments. Since this is unrealistic, using Rigidbody and physics to create such controls is impractical and the effect will not be the same. The solution is a specialized Character Controller. It simply creates a capsule-shaped Collider that can be moved in a certain direction using a script. The controller will take care of the movement, but collisions hold it back. It will slide along walls, climb stairs (if the steps are lower than the Step Offset) , and walk on slopes given the Slope Limit.

The controller does not react to forces on its own and does not automatically repel Rigidbody objects.

If you want to push Rigidbody bodies or objects that use a Character Controller, you can apply forces to any object it crashes into via scripting using the OnControllerColliderHit () function.

On the other hand, if you want the player character to be influenced by physics, then perhaps you would be better off using Rigidbody instead of Character Controller.

More information about this type of controller can be found here -> Character Controller

Player based on Rigidbody

Rigidbodies enable your GameObjects to act under the control of physics. The Rigidbody can receive forces and torque to make your objects move in a realistic way. Any GameObject must contain a Rigidbody to be influenced by gravity, act under added forces via scripting, or interact with other objects through the NVIDIA PhysX physics engine.

Rigidbodies allow your GameObjects to act under control of the physics engine. This opens the gateway to realistic collisions, varied types of joints, and other very cool behaviors. Manipulating your GameObjects by adding forces to a Rigidbody creates a very different feel and look than adjusting the Transform Component directly. Generally, you shouldn’t manipulate the Rigidbody and the Transform of the same GameObject - only one or the other.

The biggest difference between controlling transformations and solids is the use of forces. Solid bodies can be controlled by forces and rotation, but transformations cannot. Transformations can be moved and rotated, but this is not the same as using physics. You'll notice the difference when you decide to try it out for yourself. Adding a force / rotation to a solid will change the position and rotation of the Transform component of the object. That's why you only need to use one of them. Changing the transformations when using physics can create problems in collisions and other calculations.

Rigidbodies must be explicitly added to your GameObject before they will be affected by the physics engine. You can add a Rigidbody to your selected object from Components->Physics->Rigidbody in the menu. Now your object is physics-ready; it will fall under gravity and can receive forces via scripting, but you may need to add a Collider or a Joint to get it to behave exactly how you want.

More information about this type of controller can be found here -> Rigidbody

Last updated