Jump to:
Introduction to Godot
Godot is an open-source 3D and 2D game engine. Official page
Reasons to use Godot
- Lightweight executable, extremely easy to install and opens in seconds
- Open-source, no licensing fees, a vibrant developer community
- Intuitive and easy to learn, yet not limiting
- Exporting out-of-the-box for all desktop platforms, Android, iOS and HTML5
- Indie friendly <3
Reasons NOT to use Godot
- Not proven out for AAA level teams
- Rendering pipelines are still in the works
- Poor .FBX asset compatibility
- Not as established/matured as something like Unreal
All of this page is for Godot 4.1+
GDScript recipes
Quick animation by tweening properties
Fading out an enemy sprite:
func hide_enemy():
var tween = get_tree().create_tween()
tween.tween_property(enemy_sprite, "self_modulate", Color(1,1,1,0), 0.5)
await tween.finished
enemy_sprite.visible = false
Common workflows
Quick n' dirty animated 3D character
Scene node organisation:
Base character scene (character.tscn)
Extended player character scene
- NavigationAgent3D is optional - though aids auto movement if you want to include it on the player
- Visuals have an imported model with baked-in animations, with editable children selected, so an AnimationTree can be attached to it for finer control over the animations
Scripting
All variables here referencing scene nodes are @onready'd
Visuals are updated by getting the movement/velocity direction and using a look_at:
visuals.look_at(direction)
I often have to flip the character model towards negative Z so the look_at works, though there's some optional parameters for the function that might make it work with positive Zs as well.