Home
Softono
GodotFirstPersonController

GodotFirstPersonController

Open source GDScript
157
Stars
13
Forks
1
Issues
4
Watchers
11 months
Last Commit

About GodotFirstPersonController

Basic First Person Controller for Godot 4

Platforms

Web Self-hosted

Languages

GDScript

Godot 4 - Basic First Person Controller

This project contains the basic implementation of a First Person character controller for Godot 4.

The code found in player.gd uses vector forces to move the player. You can tweak the values of the forces in the editor directly. The velocity of the player is calculated as a result of the vector sum of different vector forces: walk, jump and gravity.

The main scene is a Sandbox scene used to test the controls:

EditorView

Controls

Keys Action Name Description
W,A,S,D, left stick move_ + dir Move
mouse, right stick look_ + dir Look/Aim
Space, Xbox Ⓐ jump Apply jump force
ESC, Xbox Ⓑ exit Close the game

You can change any of this keys in: Project Settings → Input Map.