> For the complete documentation index, see [llms.txt](https://chatsystem-wiki.gitbook.io/chatsystem-wiki/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://chatsystem-wiki.gitbook.io/chatsystem-wiki/neu/msg-system.md).

# MSG System

#### Was ist das?

Ein komplett eigenständiges privates Nachrichten-System das ALLE anderen MSG-Systeme (wie EssentialsX) überschreibt, sodass man sich keine sorgen machen muss das sich irgendwas überschriebt oder es Probleme gibt! Es hat eine **eigene Config-Datei** (`msgconfig.yml`) und funktioniert unabhängig von anderen Plugins.

***

#### Befehle

| Befehl                        | Beschreibung                                         |
| ----------------------------- | ---------------------------------------------------- |
| `/msg <Spieler> <Nachricht>`  | Sendet eine private Nachricht                        |
| `/w <Spieler> <Nachricht>`    | Alias für /msg                                       |
| `/tell <Spieler> <Nachricht>` | Alias für /msg                                       |
| `/r <Nachricht>`              | Antwortet der letzten Person die dir geschrieben hat |
| `/msgignore <all/Spieler>`    | Ignoriert MSGs von allen oder bestimmten Spielern    |
| `/msgsound <true/false>`      | Schaltet den MSG-Sound ein oder aus                  |

***

#### Wie funktioniert es?

**Nachricht senden:**

text

```
/msg Rocky_QDH Hallo wie gehts?
```

**Was der SENDER sieht:**

text

```
[Ich → Rocky_QDH] Hallo wie gehts?
```

* **Hover:** "Klicke hier, um zu antworten!"
* **Klick:** `/msg Rocky_QDH` erscheint in der Chatzeile

**Was der EMPFÄNGER sieht:**

text

```
[Rocky_QDH → mir] Hallo wie gehts?
```

* **Hover:** "Klicke hier, um zu antworten!"
* **Klick:** `/msg Rocky_QDH` erscheint in der Chatzeile
* **Sound:** Ein "Pling"-Sound wird abgespielt

***

#### Antworten mit /r

Wenn dir jemand schreibt, kannst du mit `/r` direkt antworten ohne den Namen eingeben zu müssen:

text

```
/r Mir gehts gut, danke!
```

Das System merkt sich automatisch wer dir zuletzt geschrieben hat und sendet die Antwort an diese Person.

***

#### MSG Ignorieren

**Alle ignorieren:**

text

```
/msgignore all
```

→ Du bekommst von NIEMANDEM mehr private Nachrichten

**Bestimmten Spieler ignorieren:**

text

```
/msgignore Rocky_QDH
```

→ Du bekommst keine Nachrichten mehr von Rocky\_QDH

**Wieder aktivieren:**\
Den gleichen Befehl nochmal eingeben:

text

```
/msgignore Rocky_QDH
```

→ Nachrichten von Rocky\_QDH kommen wieder an

***

#### MSG Sound

**Sound aus:**

text

```
/msgsound false
```

→ Kein Sound mehr wenn du eine MSG bekommst

**Sound an:**

text

```
/msgsound true
```

→ Sound wieder aktiviert

**Status prüfen:**

text

```
/msgsound
```

→ Zeigt: "MSG Sound: AN" oder "MSG Sound: AUS"

***

#### Special Formats in MSGs

ALLE Special Formats die im normalen Chat funktionieren, funktionieren auch in MSGs:

| Format            | Beispiel                           |
| ----------------- | ---------------------------------- |
| Farbcodes         | `&cWichtige Nachricht!`            |
| Emojis            | `:heart:`                          |
| Koordinaten       | `[coords]`                         |
| Items zeigen      | `[Item]`                           |
| Klickbare Befehle | `cmd/spawn`                        |
| Link-in-Word      | `<link:{https://google.com}=hier>` |
| Kopierbarer Text  | `<copy>Text</copy>`                |

***

#### MSG Logging

ALLE privaten Nachrichten werden in einer Log-Datei gespeichert:

text

```
plugins/ChatSystem/msglogs/msglog.txt
```

Format:

text

```
[24.06.2025 15:30:22] Rocky_QDH -> Max: Hallo!
[24.06.2025 15:31:05] Max -> Rocky_QDH: Hi!
```

Die Logs werden **NIE gelöscht** und sind unbegrenzt.

***

#### Eigene Config (`msgconfig.yml`)

Das MSG-System hat eine EIGENE Config-Datei die mit `/chatsystem reload` neu geladen wird:

yaml

```
msg:
  format:
    sender: "&8[&7Ich &8→ &7{target}&8] &f{message}"
    target: "&8[&7{sender} &8→ &7mir&8] &f{message}"
  hover:
    sender: "&7Klicke hier, um zu antworten!"
    target: "&7Klicke hier, um zu antworten!"
  sound:
    name: "ENTITY_EXPERIENCE_ORB_PICKUP"
    volume: 0.5
    pitch: 1.0
```

**Erklärung der Einstellungen:**

| Einstellung     | Beschreibung                 |
| --------------- | ---------------------------- |
| `format.sender` | Was der SENDER sieht         |
| `format.target` | Was der EMPFÄNGER sieht      |
| `hover.sender`  | Hover-Text für den Sender    |
| `hover.target`  | Hover-Text für den Empfänger |
| `sound.name`    | Sound-Name (Bukkit Sound)    |
| `sound.volume`  | Lautstärke (0.0 - 1.0)       |
| `sound.pitch`   | Tonhöhe (0.5 - 2.0)          |

***

#### Überschreibt andere Plugins

Das ChatSystem MSG registriert die Befehle `/msg`, `/w`, `/tell`, `/r` mit HOHEM Priority. Das bedeutet:

* ✅ EssentialsX `/msg` wird überschrieben
* ✅ Andere MSG-Plugins werden überschrieben
* ✅ Alle MSGs laufen NUR noch über das ChatSystem
* ✅ Alle Features (Hover, Klick, Sound, Logging) sind aktiv

***

#### Tab-Completion

| Befehl       | Tab-Vorschläge               |
| ------------ | ---------------------------- |
| `/msg`       | Alle Online-Spieler          |
| `/w`         | Alle Online-Spieler          |
| `/tell`      | Alle Online-Spieler          |
| `/r`         | `<Nachricht>`                |
| `/msgignore` | `all` + Alle Online-Spieler  |
| `/msgsound`  | `true`, `false`, `on`, `off` |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://chatsystem-wiki.gitbook.io/chatsystem-wiki/neu/msg-system.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
