Skip to main content

How to Install Godot 4 on Ubuntu (Linux)

How to Install Godot 4 on Ubuntu (Linux)

In this article, I will show you how to install the Godot 4 game engine on Ubuntu (Linux).

info

These steps were tested on a Dell XPS 13 running Ubuntu 20.04.6 LTS.

I tried originally to install the .NET version for C# support. But I had some issues. So I decided to install the non-C# version on Ubuntu.

Step 1. Use snap

After wrestling with several other ways of installing Godot 4, it turned out that using snap was the simplest and easiest solution.

You can find the steps here: https://snapcraft.io/install/godot-4/debian

The steps from that article do the following (I added the comments):

# run basic updates
sudo apt update
sudo apt install snapd

# you might be told that this was installed already
sudo snap install core

# install godot-4
sudo snap install godot-4 --edge

Step 2. Run Godot 4

Once Godot 4 is installed you can run it using the binary godot-4.

For example, open up a terminal window and run this command:

godot-4 --version

To see help for the binary, use this command:

godot-4 --help

Step 3. Open up the editor

Before opening up the editor, do the following:

mkdir -p ~/projects/godot/godot-demo

cd ~/projects/godot/godot-demo

Now open up the editor using the -e flag:

godot-4 -e

Step 4. Run a demo

If any dialog box popped up, clear it.

  • Click on the Asset Library Projects tab
  • If you don't see any demos, click on Support in the upper right and check Community
  • Double-click a project - I selected the Match 3 Game Template
  • Click Download
  • In the Path field append to your home path /projects (example: /home/mitch/projects)
  • Click the godot folder and then the godot-demo folder
  • Click Select Current Folder
  • Click Install & Edit

By default, the editor starts in the 3D view.

  • Click the 2D tab on the top

To run the demo, you should see a set of buttons near the top right of the editor. They will look like video controls.

  • Press the play button (it looks like a triangle)
  • Play around with the demo
  • In the case of a Match 3 / Tile Matching game (like Bejeweled and Candy Crush), just drag the tiles to match 3 in a row

Be aware that the demo is in its own window and may end up behind the editor.

Step 5. Run the build from the command line

To run just the build from the command line:

  • Quit Godot
  • Make sure you are in the projects directory (/projects/godot/godot-demo)
  • Just run this command from that directory:
godot-4

Just the build should come up.

To launch the editor, close the build and run the command with the -e option:

godot-4 -e

Step 6. Add to favorites

While Godot 4 is running you will see it in the launcher window on your desktop. But it will be gone as soon as you close it or reboot. To keep Godot on the launcher, do the following:

  • Hold your mouse down on the Godot icon on the desktop launcher
  • Select Add to Favorites

Conclusion

In this article, you learned how to:

  • Install and run Godot 4 on Ubuntu
  • Switch on Community support to build and run the demos
  • Launch the build or the editor from the command line
  • Add it to the desktop launcher

References

  • Godot Engine - [1]
  • Godot 4.0 sets sail - [2]
  • Install godot-4 on Debian - [3]
  • Godot Demo Projects - [4]
  • Godot Command Line Tutorial - [5]
  • Your first 2D game - [6]
  • Godot Scripting Languages - [7]