# Garry's Mod

Tebex supports seamless integration with **Garry’s Mod (GMod)**, allowing you to monetize your server through webstore packages, commands, and automated item delivery.

> 📦 **Plugin Download:**\
> Visit your **Tebex Control Panel → Plugins** section to download the Garry’s Mod plugin, or use the latest release from GitHub.

***

### Plugin Installation Guide

#### 1. **Download and Extract the Plugin**

* Download the latest **Tebex GMod Plugin** from the [Plugins section](https://creator.tebex.io/game-servers).
* Extract the downloaded `.zip` file. You will get a folder named:

```
tebexgmod/
```

#### 2. **Upload the Plugin to Your Server**

* Place the entire `tebexgmod/` directory into the following location on your server:

```
garrysmod/addons/tebexgmod/
```

> Ensure the full path to the plugin looks like:\
> `garrysmod/addons/tebexgmod/`

#### 3. **Start or Restart Your Server**

* If your server is already running, the plugin should **auto-load**.
* Otherwise, start the server to load the plugin.

#### 4. **Link Your Tebex Store**

* In the server console, enter:

```plaintext
tebex:secret your-secret-key
```

> You can find your **secret key** by going to the **Game Servers** section in your Tebex Control Panel and clicking **Edit** on your server entry.

***

### Verifying Setup

Once linked, the plugin will confirm the successful installation in your server console.

To view plugin status and server-store connection details, run:

```plaintext
tebex:info
```

To see all available plugin commands:

```plaintext
tebex:help
```

***

### Optional Integrations

Tebex also supports advanced integration options including:

* **Webhooks**
* **MySQL**
* **RCON**

These allow more automation and cross-platform communication between your GMod server and external systems.

***

### ⚠ Important Configuration Notes

#### 🔹 Customizing the Player Command

* By default, players use `!donate` in chat to open the webstore.
* To change this command, edit the generated `config.txt` located in:

```
data/tebex/
```

#### 🔹 Ensuring Command Execution After Restart

Due to how **GMod’s timer system** works:

* The **command checker won’t start automatically** after a restart until **a player joins** the server.
* To ensure the checker starts on boot, add this setting to your server config:

<pre class="language-plaintext"><code class="lang-plaintext"><strong>sv_hibernate_think 1
</strong></code></pre>

This forces GMod to run timers even when no players are online.

### Academy Video

{% embed url="<https://www.youtube.com/watch?v=9_WEsl7nHsQ>" %}


---

# 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://docs.tebex.io/creators/tebex-control-panel/game-servers/garrys-mod.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.
