Download Godot from the official website, then install and run it.
Godot Download Page
Create a New Project: In the Project Manager, click “New Project” and select an empty folder for your files.
Give it a relevant name.
Organise Files: In your project, create folders like:
Assets/ for images and sounds
Scenes/ for different scenes (e.g. Scenes/Player.tscn, Scenes/World.tscn)
Scripts/ for your scripts (e.g. Scripts/Player.gd)
Import Images: Put any images you’d like to use into a folder called ‘images’ or similar. Godot will automatically load them in the FileSystem dock.
It’s helpful to keep your folder structure tidy so you can quickly find and modify resources. Just like setting up your campsite properly in a survival game, having an organised project makes every task much easier later.
Godot uses a hierarchical node system to build your game. Think of nodes like building blocks. For a top-down survival game, you might create:
A Main Scene (e.g. Game.tscn) containing global elements like a camera or UI.
A Player Scene (e.g. Player.tscn) that has a root Node2D with child nodes for the sprite and collision.
Example workflow:
Create a new scene (Scene > New Scene) and add a Node2D as the root. Call it Player.
Add a Sprite2D child to display your player image.
Add a CollisionShape2D to detect collisions (you can draw a rectangle or circle shape).
Save the scene in Scenes/Player.tscn. Then, in your main scene (Game.tscn), instance the Player.tscn by dragging it from the FileSystem panel into the scene tree.
Official docs on Scenes
Please use this link to see Godot's official documentation on all nodes
In the example to the left, you can see a typical node set up for a very basic game. Let's run through it all:
Main: Think of this as the stage floor where all of your actors, props, and effects are placed. It doesn't do anything by itself, but it's a crucial starting point, a container of sorts to allow the rest of the organisation to happen.
Player: This node's type is a CharacterBody2D, but we've renamed it to 'Player'. It still has all the necessary properties and behaviours embedded and expected of a CharacterBody2D node. This includes behaviours that make the players slide down slopes, or hang on to a ceiling, or the ever-useful move_and_slide()function which means if two bodies collide with one another they'll slide along rather than stopping immediately. Lots can be done with this, from melee combat to push/pull puzzles.
Attaching scripts to nodes is like attaching a brain to your survival hero. In Godot 4.3, scripts are best placed in Scripts/. Below is a straightforward GDScript example. Remember to use the 2D workspace (Canvas mode) for a top-down approach.
Player Movement Script
Attach the script: Select your Player root node, click the “Attach Script” button, and save it as Player.gd in Scripts/.
Enable input: Go to Project > Project Settings > Input Map to set up actions like ui_up, ui_down, ui_left, ui_right, or create custom actions such as move_up.
This is where you can add any custom controls and connect them to specific keystrokes, mouseclicks, gamepad buttons or gamepad joysticks.
Key points:
We use _physics_process(delta) to handle movement based on framerate-independent physics ticks.
Input.is_action_pressed("ui_up") checks if a key is held down. Don’t use this for toggle-effects or one-off actions. There are other code pieces for that.
@export allows you to tweak variables easily in the Godot inspector.
Commenting is important. Go through the code to the left. Write a short comment for every line explaining it in your own words. We’ll get more formal later, for now, just show understanding as best you can.
Normalization:
https://youtube.com/shorts/0cYjreg7dpg?si=UDO8Yb4PBzL4MX91