# Linking System

{% hint style="info" %}
Players can link their Steam account with their Discord account. Linked players can get special benefits like permissions or special roles on your Discord. Additional modules also bring another benefits.<br>

### 🚨 How can players link their accounts?

1. Just type the command <mark style="color:green;">**`!link`**</mark> on your CS2 server (Or if you have created other commands in **Ingame Link Commands**)\
   \- This will generate a code
2. Then on your Discord server just use the Slash Command <mark style="color:green;">**`/link`**</mark> and paste the generated code
3. And that's it, the players have linked their accounts
   {% endhint %}

{% hint style="danger" %}
To activate the Link system, you must have filled your database details!
{% endhint %}

<div align="left"><figure><img src="https://799349702-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrczaiIR8LCIvnID1U1Ty%2Fuploads%2FwXCGXNZxe61TcJ76BWW9%2Flinked.png?alt=media&#x26;token=5cee06d8-1dc7-452d-a195-5b019d67bc0c" alt="" width="431"><figcaption></figcaption></figure></div>

<table><thead><tr><th width="302">Property</th><th width="438">Description</th></tr></thead><tbody><tr><td><strong>Enabled</strong></td><td>If this feature will be available <mark style="color:green;"><code>true</code></mark> / <mark style="color:red;"><code>false</code></mark> </td></tr><tr><td><strong>Code Length</strong></td><td>How length the codes will be generated</td></tr><tr><td><strong>Response Server</strong></td><td>Which server will respond to the Link Slash Command ( <mark style="color:green;"><code>true</code></mark> / <mark style="color:red;"><code>false</code></mark>  )<br>So if you have multiple servers, set this value to true on only one server and false on all others<br><mark style="color:red;">Only one server can have Response server enabled!</mark> </td></tr><tr><td><strong>Ingame Link Commands</strong></td><td>The list of ingame commands to link discord account</td></tr><tr><td><strong>Ingame Unlink Commands</strong></td><td>The list of ingame commands to unlink discord account</td></tr><tr><td><strong>Discord Link Command</strong></td><td>The name of discord command to link steam account</td></tr><tr><td><strong>Discord Link Description</strong></td><td>Discord link command label</td></tr><tr><td><strong>Discord Link Option Description</strong></td><td>Discord link command option label</td></tr><tr><td><strong>Discord Link Option Name</strong></td><td>Discord link command option name</td></tr><tr><td><strong>Link Ingame Permissions</strong></td><td>What flag/group does a player get ingame when he have a linked account (Can't be empty!)</td></tr><tr><td><strong>Link Role ID</strong></td><td>What role does a user get on the discord server when he have a linked account (Can't be empty!)</td></tr></tbody></table>

{% hint style="success" %}
**To edit the embeds, follow the instructions:** [**Custom Embeds Format**](https://docs.sourcefactory.eu/discord-utilities/tutorials/custom-embeds-format)<br>

> **Available Variables:**

**• Success Embed**\
&#x20;  **-&#x20;**<mark style="color:blue;">**{**</mark><mark style="color:blue;">STEAM</mark><mark style="color:blue;">**}**</mark> > Displays the SteamID64 of the linked steam account.\
\&#xNAN;**• Failed Embed**\
&#x20;  **-&#x20;**<mark style="color:blue;">**{**</mark><mark style="color:blue;">CODE</mark><mark style="color:blue;">**}**</mark> > Displays the entered code\
\&#xNAN;**• Already Linked Embed**\
&#x20;  **-&#x20;**<mark style="color:blue;">**{**</mark><mark style="color:blue;">STEAM</mark><mark style="color:blue;">**}**</mark> > Displays the SteamID64 of the linked steam account.
{% endhint %}

***

{% hint style="danger" %} <mark style="color:red;">**CAUTION**</mark>

• Your Discord BOT role must always be above your Linked Role! Otherwise role will not be added.\
• Only CSS flags work, you can't use flags from metamod plugins\
• To create Linked codes between servers your Discord BOT creates Discord Schedule Events (You can have a spammed Audit Log)
{% endhint %}

<div align="left"><figure><img src="https://799349702-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrczaiIR8LCIvnID1U1Ty%2Fuploads%2FZplZuAYBSF3jbX4jxRBZ%2Fmustbeupper.png?alt=media&#x26;token=ab4b1074-37dc-415b-bb11-907009557b64" alt="" width="341"><figcaption></figcaption></figure></div>
