# Install Flatpaks

Both P4G and **Reloaded II**, the program we use to mod it, are Windows binaries, but we can't install the modding prerequisites for P4G CEP the traditional way on Linux.

We'll need some additional tools in order to get Reloaded II working on the Steam Deck:

* **Protontricks**: This tool lets you configure the Proton compatibility layer for Steam games—it's like Winetricks, but for Proton! We'll use it to install the prerequisite runtimes Reloaded II needs.
* **Flatseal:** This tool lets you configure the permissions given to **flatpak** applications. We're going to use it to give **Protontricks** access to your microSD card.

<details>

<summary>Useful Terms</summary>

* **Proton:** A compatibility layer by Valve that can make Windows games run on Linux. It's a combination of two other open-source projects, Wine and DXVK.
* **Flatpak:** A platform for running packaged applications called **flatpaks**. Flatpaks are the ideal way to get new software on the Steam Deck and other immutable distros as they will persist between major OS updates.
* **Flathub:** Think of this as the "app store" for flatpaks. It's a repository where creators and community maintainers can upload flatpaks for users to install.
* **Discover:** A software center application by KDE that lets users easily browse, install, and update flatpaks.&#x20;

</details>

## Install Prerequisite Flatpaks

{% hint style="success" %}
Want to use the command line instead?

```
flatpak install flathub com.github.tchx84.Flatseal
flatpak install flathub com.github.Matoking.protontricks
```

{% endhint %}

### Launch Discover

* Open the application launcher and launch **Discover** under the **System** tab.

<figure><img src="/files/3b1tiBPDKP3f9OYz2weU" alt=""><figcaption></figcaption></figure>

### Install Flatseal

* Find the search bar in the top-left of the Discover window and search for **Flatseal**.
* Once it appears on the right, select **Flatseal**.
* Select **Install** in the top-right. Do not launch the program yet!

<figure><img src="/files/PZAGeskAu3yZFzPLQXI1" alt=""><figcaption></figcaption></figure>

### Install Protontricks&#x20;

* Use the search bar again to search for **Protontricks**.
  * Once it appears on the right, select **Protontricks**.
  * Select **Install in** the top-right. Do not launch the program yet!

<figure><img src="/files/recARLQNHBeAZX9HPbNC" alt=""><figcaption></figcaption></figure>

## Moving On

{% content-ref url="/pages/EIfSu3avviJcWB4LY27L" %}
[Steam and P4G](/install/steam-and-p4g.md)
{% endcontent-ref %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://p4g-deck.cep.one/install/install-flatpaks.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
