A lightweight, Unity-based first-person controller inspired by the classic Quake movement system. Built with C# and Unity's Rigidbody physics, this project aims to replicate the snappy, skill-expressive feel of retro arena shooters.
- Responsive ground movement (WASD)
- Quake-style air control — change direction mid-air
- Friction system for smooth deceleration
- Jump with configurable force
- Ground detection via overlap check
- Modular and easy to extend
- Works with Unity Input System
| Tool | Version |
|---|---|
| Unity | 2021.3 LTS or higher |
| Input System Package | Required |
| Rigidbody | Attached to player object |
- Clone the repository:
git clone https://github.com/fixin0/BasicQuakeLikeFPSController.git-
Open in Unity:
- Launch Unity Hub
- Click Open and select the cloned folder
-
Configure the Player GameObject:
- Add a Rigidbody component:
- Interpolation:
Interpolate - Collision Detection:
Continuous Dynamic - Freeze Rotation: X, Y, Z
- Interpolation:
- Add a Capsule Collider
- Add an empty child object and assign it as
groundChecker - Add a Camera as a child of the Player (for the view)
- Add a Rigidbody component:
-
Attach the script:
- Add
PlayerController.csto your Player GameObject - Wire up the
groundCheckertransform and camera reference in the Inspector
- Add
-
Input System:
- Make sure the Input System package is installed via Package Manager
- The project uses a
GeneralInputaction map with:Movement→ Vector2Jump→ Button
| Action | Input |
|---|---|
| Move | W A S D / Arrow Keys |
| Jump | Space |
| Parameter | Description |
|---|---|
moveSpeed |
Base walking speed |
jumpForce |
Upward force applied on jump |
groundAccelerate |
Acceleration rate on the ground |
airAccelerate |
Acceleration rate while airborne |
maxGroundSpeed |
Maximum speed on the ground |
maxAirSpeed |
Maximum speed in the air |
stopSpeed |
Speed threshold below which friction kicks in fully |
groundFriction |
How quickly the player decelerates on the ground |
airControl |
How much the player can steer while in the air |
mouseSensitivity |
Camera look sensitivity |