# Introduction

Welcome to the new wiki of TChat!

Spigot:

{% embed url="<https://www.spigotmc.org/resources/tchat-1-13-1-21-1-the-most-advanced-chat-plugin.111858/>" %}

Modrinth:

{% embed url="<https://modrinth.com/plugin/tchat/>" %}

Made by:

{% embed url="<https://tect.host/>" %}


# Actions

Actions are configurable operations that can be attached to certain modules. When triggered, the plugin executes the configured actions in the order they are defined. Actions can perform various tasks such as sending messages, playing sounds, applying effects, executing commands, modifying player data, and more.

***

## Messaging

#### \[MESSAGE]

Sends a chat message to the player.

```yml
actions:
- "[MESSAGE] &aWelcome to the server!"
```

#### \[BROADCAST]

Sends a message to all online players. (Not visible in the console)

```yaml
actions:
- "[BROADCAST] &6A special event has started!"
```

#### \[PRINT]

Sends a global message. (Visible in the console)

```yaml
actions:
- "[PRINT] <gray>Just a global message."
```

***

## Debug

#### \[DEBUG]

Writes a message to the console log. You can specify the log level.

```yaml
actions:
- "[DEBUG] INFO Player joined the server"
- "[DEBUG] WARN Invalid configuration detected"
- "[DEBUG] WARNING Invalid configuration detected"
- "[DEBUG] SEVERE Database connection failed"
- "[DEBUG] ERROR Database connection failed"
- "[DEBUG] FINE Processing message from player %player_name%"
- "[DEBUG] DEBUG Processing message from player %player_name%"
```

***

## Visual

#### \[TITLE]

Displays a title and optional subtitle on the player's screen.

Format: title;subtitle

```yaml
actions:
- "[TITLE] &aWelcome!;&7Enjoy your stay."
```

#### \[ACTION\_BAR]

Displays a message in the player's action bar.

```yaml
actions:
- "[ACTION_BAR] &eYou are in a safe zone."
```

***

## Commands

#### \[PLAYER\_COMMAND]

Executes a command as the player.

```yaml
actions:
- "[PLAYER_COMMAND] spawn"
- "[PLAYER_COMMAND] kit starter"
```

#### \[CONSOLE\_COMMAND]

Executes a command from the server console.

```yaml
actions:
- "[CONSOLE_COMMAND] give %player_name% diamond 1"
```

***

## World

#### \[SOUND]

Plays a Minecraft sound for the player.

```yaml
actions:
- "[SOUND] entity_player_levelup"
```

#### \[PARTICLE]

Spawns particles at the player's location.

```yaml
actions:
- "[PARTICLE] flame"
```

#### \[TELEPORT]

Teleports the player to a specific location.

Format: world;x;y;z

```yaml
actions:
- "[TELEPORT] world;100;64;200"
```

***

## Inventory

#### \[INVENTORY]

Modifies the player's inventory.

* ADD
  * Adds items to the player's inventory.
* REMOVE
  * Removes items from the player's inventory.
* CHANGE
  * Removes one item and gives another.

```yaml
actions:
- "[INVENTORY] ADD DIAMOND 5"
- "[INVENTORY] REMOVE DIAMOND 5"
- "[INVENTORY] CHANGE COAL 10 DIAMOND 1"
```

***

## Potion Effects

#### \[POTION\_EFFECT]

Adds or removes potion effects.

Format: TYPE:duration:amplifier

* ADD
  * Applies a potion effect.
* REMOVE
  * Removes a potion effect.

```yaml
actions:
- "[POTION_EFFECT] ADD SPEED:1200:1"
- "[POTION_EFFECT] ADD REGENERATION:200:2"
- "[POTION_EFFECT] REMOVE SPEED"
```


# Conditionals

Conditional actions allow you to execute different actions depending on whether a condition is true or false.

***

## \[IF]

<pre class="language-yaml"><code class="lang-yaml"><strong>actions:
</strong><strong>- "[IF] {player} == 'TectHost'"
</strong>- "[MESSAGE] Hello!"
- "[ENDIF]"
</code></pre>

The actions between `[IF]` and `[ENDIF]` are only executed if the condition evaluates to `true`.

## \[ELSE IF]

```yaml
actions:
- "[IF] {player} == 'TectHost'"
- "[MESSAGE] Hello TectHost!"
- "[ELSE IF] %vault_eco_balance% >= '1000'"
- "[MESSAGE] You are rich!"
- "[ENDIF]"
```

`[ELSE IF]` is only evaluated if every previous condition in the same block was false.

You can have as many `ELSE IF` blocks as you want.

## \[ELSE]

```yaml
actions:
- "[IF] {player} == 'TectHost'"
- "[MESSAGE] Hello TectHost!"
- "[ELSE]"
- "[MESSAGE] Hello everyone else!"
- "[ENDIF]"
```

The `ELSE` block is executed only if none of the previous conditions matched.

Only one `ELSE` block is allowed per `IF`.

## \[ENDIF]

```yaml
actions:
- "[ENDIF]"
```

Marks the end of the conditional block.

Every `[IF]` must have a matching `[ENDIF]`.

## Nested Actions

```yaml
actions:
  - "[IF] {player} == 'TectHost'"
  - "[MESSAGE] Welcome!"

  - "[IF] %vault_eco_balance% >= '1000'"
  - "[MESSAGE] You're also rich!"
  - "[ENDIF]"

  - "[ENDIF]"
```

Nested `IF` blocks work independently and must each have their own matching `[ENDIF]`.

## Example

```yaml
actions:
  - "[IF] {player} == 'TectHost'"
  - "[MESSAGE] <green>Welcome back, owner!"

  - "[IF] %vault_eco_balance% >= '100000'"
  - "[MESSAGE] <gold>You have over $100,000!"
  - "[ELSE IF] %vault_eco_balance% >= '10000'"
  - "[MESSAGE] <yellow>You have over $10,000."
  - "[ELSE]"
  - "[MESSAGE] <gray>You should earn some more money."
  - "[ENDIF]"

  - "[ELSE IF] %player_level% >= '100'"
  - "[MESSAGE] <aqua>You're a high-level player!"

  - "[IF] %player_world% == 'world_nether'"
  - "[MESSAGE] <red>Be careful in the Nether!"
  - "[ELSE]"
  - "[MESSAGE] <green>Enjoy your adventure!"
  - "[ENDIF]"

  - "[ELSE IF] %vault_eco_balance% >= '1000'"
  - "[MESSAGE] <yellow>You have at least $1,000."

  - "[ELSE IF] %player_ping% >= '200'"
  - "[MESSAGE] <red>Your connection seems slow."

  - "[ELSE]"
  - "[MESSAGE] <gray>Welcome to the server!"
  - "[ENDIF]"

  - "[MESSAGE] <white>This message is always executed."
```


# Loops

Loop actions allow you to execute the same group of actions multiple times.

## \[FOR]

```yaml
actions:
- "[FOR] 5"
- "[MESSAGE] Hello!"
- "[ENDFOR]"
```

Executes all actions between `[FOR]` and `[ENDFOR]` the specified number of times.

In this example, the player receives **5** messages.

## \[ENDFOR]

```yaml
actions:
- "[ENDFOR]"
```

Marks the end of the loop.

Every `[FOR]` must have a matching `[ENDFOR]`.

## Nested Loops

```yaml
actions:
  - "[FOR] 2"

  - "[MESSAGE] Outer loop"

  - "[FOR] 3"
  - "[MESSAGE] Inner loop"
  - "[ENDFOR]"

  - "[ENDFOR]"
```

Loops can be nested.

Execution:

```
Outer loop
  Inner loop
  Inner loop
  Inner loop

Outer loop
  Inner loop
  Inner loop
  Inner loop
```

The outer loop runs 2 times, and during each iteration the inner loop runs 3 times, resulting in 6 executions of the inner message.

## Dynamic count

The number of iterations can be any expression supported by the expression engine.

```yaml
actions:
  - "[FOR] {arg0}"
  - "[MESSAGE] Hello!"
  - "[ENDFOR]"
```

If the player executes:

```
/example 4
```

The message will be sent 4 times.

## Example

```yaml
actions:
  - "[MESSAGE] <gray>Starting command for <yellow>{player}</yellow>..."

  - "[FOR] {arg0}"

  - "[MESSAGE] <green>Iteration #{arg0}"
  - "[SOUND] entity.player.levelup"

  - "[IF] {arg1} == 'fire'"
  - "[CONSOLE_COMMAND] effect give {player} fire_resistance 5 0 true"

  - "[ELSE IF] {arg1} == 'heal'"
  - "[CONSOLE_COMMAND] effect give {player} instant_health 1 1 true"

  - "[ELSE IF] {arg1} == 'speed'"
  - "[CONSOLE_COMMAND] effect give {player} speed 5 1 true"

  - "[ELSE]"
  - "[MESSAGE] <gray>No effect selected."
  - "[ENDIF]"

  - "[MESSAGE] <yellow>Arguments:</yellow> {args}"

  - "[ENDFOR]"

  - "[MESSAGE] <green>Loop finished successfully!"
```


# Storage

Here you can choose how you want to save the plugin's data

```yml
# Methods
#   Local databases:
#    - SQLite
storage:
  method: SQLite
  remote:
    host: localhost
    port: 3306
    database: tchat
    username: root
    password: ""
```

* storage.method: The database type.
* storage.remote.host: The IP address of the database server.
* storage.remote.port: The port of the database server.
* storage.remote.database: The database name (provided by the database server).
* storage.remote.username: The username of the database server.
* storage.remote.password: The password of the database server.


# Commands and permissions

## Permissions

{% tabs %}
{% tab title="Commands" %}
Permission for all user commands: `tchat.command`\
Permission for all commands: `tchat.admin.command`

| Command                          | Permission                                                                                                 |
| -------------------------------- | ---------------------------------------------------------------------------------------------------------- |
| /nick                            | tchat.command.nick                                                                                         |
| /channel, /ch                    | tchat.command.channel                                                                                      |
| /print                           | tchat.command.print                                                                                        |
| /heal                            | tchat.command.heal                                                                                         |
| /me                              | tchat.command.me                                                                                           |
| /chat reload                     | tchat.admin.command.reload                                                                                 |
| /blockedwords                    | tchat.admin.command.blockedwords                                                                           |
| /nick (others)                   | tchat.admin.nick.others                                                                                    |
| /blockchat, /chatblock, /muteall | tchat.admin.command.blockchat                                                                              |
| /invsee                          | tchat.admin.command.invsee (It can be used by regular users, but I recommend that only admin users use it) |
| /announcement                    | tchat.admin.command.announcement                                                                           |
| /broadcast                       | tchat.admin.command.broadcast                                                                              |
| /warning                         | tchat.admin.command.warning                                                                                |
| /chatclear                       | tchat.admin.command.chatclear                                                                              |
| {% endtab %}                     |                                                                                                            |

{% tab title="Bypass" %}
Permission for bypass all: `tchat.admin.bypass`

| Action                         | Permission                         |
| ------------------------------ | ---------------------------------- |
| Bypass blocked words module    | tchat.admin.bypass.blockedwords    |
| Bypass blocked commands module | tchat.admin.bypass.blockedcommands |
| Bypass blocked chat module     | tchat.admin.bypass.blockchat       |
| Bypass anti cap module         | tchat.admin.bypass.anticap         |
| Bypass block chat (worlds)     | tchat.admin.bypass.worlds.chat     |
| Bypass anti advertising module | tchat.admin.bypass.antiadvertising |
| Bypass anti spam module        | tchat.admin.bypass.antispam        |
| Bypass grammar module          | tchat.admin.bypass.grammar         |
| Bypass anti unicode module     | tchat.admin.bypass.antiunicode     |
| {% endtab %}                   |                                    |

{% tab title="Other" %}

| Action                                                               | Permission                |
| -------------------------------------------------------------------- | ------------------------- |
| Notifies administrators upon joining the server about plugin updates | tchat.admin.check-updates |
| {% endtab %}                                                         |                           |
| {% endtabs %}                                                        |                           |


# Color Chat

## Permissions

Permission for everything: `tchat.colorchat`

{% tabs %}
{% tab title="Colors" %}

| Color                                 | Permission                          |
| ------------------------------------- | ----------------------------------- |
| All colors                            | tchat.colorchat.colors              |
| Black \| &0 \| \<black>               | tchat.colorchat.color.black         |
| Dark blue \| &1 \| \<dark\_blue>      | tchat.colorchat.color.dark\_blue    |
| Dark\_green \| &2 \| \<dark\_green>   | tchat.colorchat.color.dark\_green   |
| Dark\_aqua \| &3 \| \<dark\_aqua>     | tchat.colorchat.color.dark\_aqua    |
| Dark\_red \| &4 \| \<dark\_red>       | tchat.colorchat.color.dark\_red     |
| Dark\_purple \| &5 \| \<dark\_purple> | tchat.colorchat.color.dark\_purple  |
| Gold \| &6 \| \<gold>                 | tchat.colorchat.color.gold          |
| Gray \| &7 \| \<gray>                 | tchat.colorchat.color.gray          |
| Dark\_gray \| &8 \| \<dark\_gray>     | tchat.colorchat.color.dark\_gray    |
| Blue \| &9 \| \<blue>                 | tchat.colorchat.color.blue          |
| Green \| \&a \| \<green>              | tchat.colorchat.color.green         |
| Aqua \| \&b \| \<aqua>                | tchat.colorchat.color.aqua          |
| Red \| \&c \| \<red>                  | tchat.colorchat.color.red           |
| Pink \| \&d \| \<pink>                | tchat.colorchat.color.light\_purple |
| Yellow \| \&e \| \<yellow>            | tchat.colorchat.color.yellow        |
| White \| \&f \| \<white>              | tchat.colorchat.color.white         |
| {% endtab %}                          |                                     |

{% tab title="Formats" %}

| Format                                   | Permission                           |
| ---------------------------------------- | ------------------------------------ |
| All formats                              | tchat.colorchat.formats              |
| Bold \| \&b \| \<bold>                   | tchat.colorchat.format.bold          |
| Italic \| \&o \| \<italic>               | tchat.colorchat.format.italic        |
| Underlined \| \&n \| \<underlined>       | tchat.colorchat.format.underlined    |
| Strikethrough \| \&m \| \<strikethrough> | tchat.colorchat.format.strikethrough |
| Obfuscated \| \&k \| \<obfuscated>       | tchat.colorchat.format.obfuscated    |
| Reset \| \&r \| \<reset>                 | tchat.colorchat.format.reset         |
| {% endtab %}                             |                                      |

{% tab title="Advanced" %}

| Action                                | Permission                        |
| ------------------------------------- | --------------------------------- |
| All advanced actions                  | tchat.colorchat.advanced          |
| Hex color \| <\&#RRGGBB>              | tchat.colorchat.advanced.hex      |
| Gradient \| \<gradient:color1:color2> | tchat.colorchat.advanced.gradient |
| Rainbow \| \<rainbow>                 | tchat.colorchat.advanced.rainbow  |
| {% endtab %}                          |                                   |
| {% endtabs %}                         |                                   |


# Utils

## Support

{% hint style="success" %}
Have you found an error? Report it here!

[Discord](https://dc.tect.host/)

[GitHub issues](https://github.com/TectHost/TChat5/issues)
{% endhint %}

## MiniMessage Support

All TChat messages, titles, actionbars, etc... support MiniMessage actions, if there is any message that does not work MiniMessage actions, it is an **error**, please report it.

## HEX Support

All TChat messages, titles, actionbars, etc... support HEX colors, if there is any message that does not work HEX colors, it is an **error**, please report it.

## PlaceholderAPI Support

All TChat messages, titles, actionbars, etc... support **PlaceholderAPI** placeholders, if there is any messages that does not work **PlaceholderAPI** placeholders, it is an **error**, please report it.


# Placeholders

{% tabs %}
{% tab title="Global" %}

| Placeholder     | Description                       | Example output  |
| --------------- | --------------------------------- | --------------- |
| %tchat\_prefix% | Returns the prefix of their group | &4\&lOwner      |
| %tchat\_suffix% | Returns the suffix of their group | \&b\&lTect Team |
| %tchat\_group%  | Returns the name of their group   | admin           |
| %tchat\_nick%   | Returns their display name        | MyUserName14    |
| {% endtab %}    |                                   |                 |
| {% endtabs %}   |                                   |                 |


# Configuration

Configuration file: modules/antiadvertising.yml

## General

```yml
modules:
  # Detects and blocks/censors IP addresses, domain names and URLs in chat
  #
  # Anti advertising module loaded from modules/antiadvertising.yml
  anti-advertising: true
```

* modules.anti-advertising: Enable/disable the module

***

## Module

#### Action

```yml
# What to do when an advertising word is detected:
# - CENSOR: Replace only the matched characters with censor-char
# - BLOCK: Cancel the message entirely
action: BLOCK
```

* BLOCK: Cancels the message.
* CENSOR: Replace the uppercase letters with the 'censor-char' character.

#### Censor-char

```yml
# Only used if action = 'CENSOR'
censor-char: "*"
```

* The censor character for the 'CENSOR' action.

#### Filters

```yaml
# Enable/disable the anti advertising filters
filters:

  # Examples: 192.168.1.1, 192.168.1.
  ipv4: true

  # Examples: 2001:db8::1, [::1]:25565
  ipv6: true

  # Examples: play.hypixel.net
  domains: true

  # Examples: www.example.com, https://example.com
  urls: true
```

* filters.ipv4: Enable/disable the IPv4 filters, example: 1.1.1.1, 192.168.0.1, 172.18.0.1, etc.
* filters.ipv6: Enable/disable the IPv6 filters, example: ::1, fd12:3456:789a::1, 2001:db8:85a3::8a2e:370:7334
* filters.domains: Enable/disable the domains filters, example: google.com, spigotmc.org, papermc.io
* filters.urls: Enable/disable the urls filters, example: <https://google.com>, <https://spigotmc.org>, <https://papermc.io>

#### Whitelist

```yaml
# Whitelist domains from all the filters
whitelist:

  # To disable this option:
  #domains: []
  domains:
    - tect.host
```

* Here you can exclude domains from the filters.

#### Custom regex

```yaml
# Custom regex patterns.
# If the pattern is invalid the plugin will use the default regex (and will send a warning in the console)
#
patterns:
  ipv4: "(?<![\\w.])(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)\\.){3}(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)(?::\\d{1,5})?|(?=\\s|$))(?![\\w.])"
  ipv6: "(?i)(?:\\[?[0-9a-f]{1,4}(?::[0-9a-f]{0,4}){2,7}]?|::(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4}|[0-9a-f]{1,4}::(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})(?::\\d{1,5})?"
  domain-url: "(?i)(?:https?://|ftp://|www\\.)?(?:[a-z0-9](?:[a-z0-9\\-]{0,61}[a-z0-9])?\\.)+(?:com|net|org|gg|io|me|co)(?:/\\S*)?"
```

* By adding this to the settings, you can customize the regex filters that TChat uses for each filter.


# Default configuration

Configuration file: modules/antiadvertising.yml

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                      antiadvertising.yml                     ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# What to do when an advertising word is detected:
# - CENSOR: Replace only the matched characters with censor-char
# - BLOCK: Cancel the message entirely
action: BLOCK
# Only used if action = 'CENSOR'
censor-char: "*"

# Enable/disable the anti advertising filters
filters:

  # Examples: 192.168.1.1, 192.168.1.
  ipv4: true

  # Examples: 2001:db8::1, [::1]:25565
  ipv6: true

  # Examples: play.hypixel.net
  domains: true

  # Examples: www.example.com, https://example.com
  urls: true

# Whitelist domains from all the filters
whitelist:

  # To disable this option:
  #domains: []
  domains:
    - tect.host

# Custom regex patterns.
# If the pattern is invalid the plugin will use the default regex (and will send a warning in the console)
#
#patterns:
#  ipv4: "(?<![\\w.])(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)\\.){3}(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)(?::\\d{1,5})?|(?=\\s|$))(?![\\w.])"
#  ipv6: "(?i)(?:\\[?[0-9a-f]{1,4}(?::[0-9a-f]{0,4}){2,7}]?|::(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4}|[0-9a-f]{1,4}::(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})(?::\\d{1,5})?"
#  domain-url: "(?i)(?:https?://|ftp://|www\\.)?(?:[a-z0-9](?:[a-z0-9\\-]{0,61}[a-z0-9])?\\.)+(?:com|net|org|gg|io|me|co)(?:/\\S*)?"

# https://tchat.tect.host/general/actions
actions:
  - "[MESSAGE] <red>Your message has been blocked.</red>"
```


# Configuration

Configuration file: modules/anticap.yml

## General

```yml
modules:
  # It lets censor, block, or convert words to
  # lowercase when they're typed in all caps
  #
  # Anti cap module loaded from modules/anticap.yml
  anti-cap: true
```

* modules.anti-cap: Enable/disable the module

***

## Module

#### Action

```yml
# Action to take when a message exceeds the cap threshold:
# - ToLowerCase : convert all uppercase letters to lowercase (recommended)
# - BLOCK : cancel the message entirely
# - CENSOR : replace uppercase letters with '*' (or the selected censor-char)
action: "ToLowerCase"
```

* ToLowerCase: Converts all to lowercase; "HELLO" -> "hello".
* BLOCK: Cancels the message.
* CENSOR: Replace the uppercase letters with the 'censor-char' character.

#### Censor-char

```yml
# Character used to replace matched letters (only relevant when action: CENSOR)
censor-char: "*"
```

* The censor character for the 'CENSOR' action.


# Default configuration

Configuration file: modules/anticap.yml

```yml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                          anticap.yml                         ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# Action to take when a message exceeds the cap threshold:
# - ToLowerCase : convert all uppercase letters to lowercase (recommended)
# - BLOCK : cancel the message entirely
# - CENSOR : replace uppercase letters with '*' (or the selected censor-char)
action: "ToLowerCase"

# Character used to replace matched letters (only relevant when action: CENSOR)
censor-char: "*"

# Fraction of letters (0.0–1.0) that must be uppercase to trigger
# Examples: 0.5 = 50% | 0.75 = 75% | 1.0 = 100% (not recommended)
# Messages with fewer than 4 letters are always ignored
percent: 0.75

# Message sent to the player when mode is BLOCK
# Supports MiniMessage tags and legacy & color codes
# Leave empty to block silently (no message shown)
message:
  - "<red>Please don't use excessive capitals."

# Coming soon...
actions: []
```


# Configuration

Configuration file: modules/antispam.yml

## General

```yml
modules:
  # Block similar letters and other types of spam in the chat.
  #
  # Anti spam module loaded from modules/antispam.yml
  anti-spam: true
```

* modules.anti-spam: Enable/disable the module

***

## Module

#### Action

```yml
# Action to execute when spam is detected.
# Available values:
# - BLOCK : cancel the message entirely.
# - CENSOR : replace uppercase letters with '*' (or the selected censor-char).
action: CENSOR
```

* BLOCK: Cancels the message.
* CENSOR: Replace the uppercase letters with the 'censor-char' character.

#### Censor-char

```yml
# Character used to replace matched letters (only relevant when action: CENSOR)
censor-char: "*"
```

* The censor character for the 'CENSOR' action.

#### Checks

```yaml
checks:

  # Repeated Characters
  # Example: "aaaaaaa", "!!!!!!!!"
  # Detects the same character repeated multiple times.
  repeated-chars:
    enabled: true
    threshold: 5

  # Repeated Pattern
  # Example: "hahahaha", "xdxdxdxd"
  # Detects short fragments repeated consecutively.
  repeated-pattern:
    enabled: true
    min-length: 2
    max-length: 4
    min-repeats: 3

  # Repeated Words
  # Example: "hello hello hello hello"
  # Detects the same word repeated multiple times.
  repeated-words:
    enabled: true
    threshold: 3

  # Character Diversity
  # Example: "asdkjfhqwe"
  # Detects long messages with very low character diversity.
  # Disabled by default to reduce false positives.
  char-diversity:
    enabled: false
    min-length: 12
    min-ratio: 0.30
```

* repeated-chars: Detects when the same character is repeated multiple times in a row.
  * enabled: Enable/disable this check.
  * threshold: Minimum number of consecutive repeated characters required to trigger detection.
* repeated-pattern: Detects when a short sequence of characters is repeated consecutively.
  * enabled: Enable/disable this check.
  * min-length: Minimum length of the repeated pattern.
  * max-length: Maximum length of the repeated pattern.
  * min-repeats: Minimum number of consecutive repetitions required before the message is flagged.
* repeated-words: Detects when the same word is repeated multiple times in succession.
  * enabled: Enable/disable this check.
  * threshold: Minimum number of consecutive repeated words required to trigger detection.
* char-diversity: Detects long messages that contain very few unique characters compared to their total length.
  * enabled: Enable/disable this check.
  * min-length: Minimum message length (excluding spaces) before the diversity check is applied.
  * min-ratio: Minimum required ratio of unique characters to total characters. Messages below this value are considered spam.

#### Whitelist

```yaml
# Words ignored by the Repeated Words check.
# Matching is case-insensitive.
whitelist:
  words:
    - "haha"
```

* List of words that are ignored by the repeated-words check.


# Default configuration

Configuration file: modules/antispam.yml

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                         antispam.yml                         ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# Action to execute when spam is detected.
# Available values:
# - BLOCK : cancel the message entirely.
# - CENSOR : replace uppercase letters with '*' (or the selected censor-char).
action: CENSOR

# Character used when action is set to CENSOR.
censor-char: "*"

checks:

  # Repeated Characters
  # Example: "aaaaaaa", "!!!!!!!!"
  # Detects the same character repeated multiple times.
  repeated-chars:
    enabled: true
    threshold: 5

  # Repeated Pattern
  # Example: "hahahaha", "xdxdxdxd"
  # Detects short fragments repeated consecutively.
  repeated-pattern:
    enabled: true
    min-length: 2
    max-length: 4
    min-repeats: 3

  # Repeated Words
  # Example: "hello hello hello hello"
  # Detects the same word repeated multiple times.
  repeated-words:
    enabled: true
    threshold: 3

  # Character Diversity
  # Example: "asdkjfhqwe"
  # Detects long messages with very low character diversity.
  # Disabled by default to reduce false positives.
  char-diversity:
    enabled: false
    min-length: 12
    min-ratio: 0.30

# Words ignored by the Repeated Words check.
# Matching is case-insensitive.
whitelist:
  words:
    - "haha"

# Actions executed when spam is detected.
actions:
  - "[MESSAGE] <red>You cannot send a message that contains spam!"
```


# Configuration

Configuration file: modules/antiunicode.yml

## General

```yml
modules:
  # Block Unicode abuse, similar-looking characters, invisible characters, and other Unicode-based chat exploits.
  #
  # Anti unicode module loaded from modules/antiunicode.yml
  anti-unicode: true
```

* modules.anti-unicode: Enable/disable the module

***

## Module

#### Action

```yml
# What to do when a disallowed unicode character is detected:
# - STRIP : Silently remove only the offending characters, keep the rest of the message
# - CENSOR : Replace only the matched characters with censor-char
# - BLOCK : Cancel the message entirely
action: STRIP
```

* STRIP: Removes the unicode characters.
* BLOCK: Cancels the message.
* CENSOR: Replace the uppercase letters with the 'censor-char' character.

#### Censor-char

```yml
# Character used to replace matched letters (only relevant when action: CENSOR)
censor-char: "*"
```

* The censor character for the 'CENSOR' action.

#### Filters

```yaml
filters:

  # Bidirectional control characters (RLO/LRO/PDF/isolates/ALM).
  # These can visually reorder text to disguise its real content ("Trojan Source" style attacks).
  # Strongly recommended to keep this enabled.
  bidi-control: true

  # Zero-width / invisible characters (ZWSP, ZWNJ, ZWJ, word joiner, BOM, soft hyphen,
  # variation selectors...)
  # e.g. "d​i​s​c​o​r​d" with invisible characters between letters.
  zero-width: true

  # Non-printable ASCII control characters (does not affect tab/newline/carriage-return)
  control-chars: true

  # "Zalgo" text, excessive stacked combining diacritical marks
  zalgo: true

  # Fullwidth forms and Mathematical Alphanumeric Symbols
  # (e.g. bold/italic unicode letters)
  fullwidth: true

  # Private Use Area characters, custom icon/font glyphs, sometimes abused for spam or ASCII-art walls
  private-use-area: true

  # Standard emoji ranges. Disabled by default since most servers allow emoji in chat.
  emoji: false

  # Restrict messages to an explicit whitelist of unicode scripts (see 'scripts.allowed' below).
  # Disabled by default, only enable this if you want to block non-Latin alphabets entirely,
  scripts: false
```

* bidi-control: Detects Unicode bidirectional control characters that can visually reorder text while leaving its actual contents unchanged.
* zero-width: Detects invisible formatting characters that cannot normally be seen by players.
* control-chars: Detects non-printable ASCII control characters.
* zalgo: Detects excessive combining diacritical marks ("Zalgo text").
* fullwidth: Detects Fullwidth Forms and Mathematical Alphanumeric Symbols.
* private-use-area: Detects characters from the Unicode Private Use Areas (PUA).
* emoji: Detects Unicode emoji characters.
* scripts: Restricts messages to specific Unicode writing systems (scripts).

#### Zalgo

```yaml
zalgo:
  # Maximum number of stacked combining marks allowed on a single base character before it's flagged
  max-combining-marks: 2
```

* max-combining-marks: Maximum number of consecutive combining marks allowed on a single character before it is considered Zalgo text.

#### Scripts

```yaml
scripts:
  # Only used if filters.scripts: true
  # Valid names: see java.lang.Character.UnicodeScript (e.g. LATIN, CYRILLIC, GREEK, HAN, ARABIC...)
  # https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Character.UnicodeScript.html
  allowed:
    - LATIN
    - COMMON
    - INHERITED
```

* Defines the Unicode scripts that are permitted when the `scripts` filter is enabled.


# Default configuration

Configuration file: modules/antiunicode.yml

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                       antiunicode.yml                        ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# What to do when a disallowed unicode character is detected:
# - STRIP : Silently remove only the offending characters, keep the rest of the message
# - CENSOR : Replace only the matched characters with censor-char
# - BLOCK : Cancel the message entirely
action: STRIP

# Only used if action = 'CENSOR'
censor-char: "*"

filters:

  # Bidirectional control characters (RLO/LRO/PDF/isolates/ALM).
  # These can visually reorder text to disguise its real content ("Trojan Source" style attacks).
  # Strongly recommended to keep this enabled.
  bidi-control: true

  # Zero-width / invisible characters (ZWSP, ZWNJ, ZWJ, word joiner, BOM, soft hyphen,
  # variation selectors...). Commonly used to evade blocked-words / anti-advertising filters,
  # e.g. "d​i​s​c​o​r​d" with invisible characters between letters.
  zero-width: true

  # Non-printable ASCII control characters (does not affect tab/newline/carriage-return)
  control-chars: true

  # "Zalgo" text, excessive stacked combining diacritical marks
  zalgo: true

  # Fullwidth forms and Mathematical Alphanumeric Symbols, often used to bypass word filters
  # (e.g. bold/italic unicode letters)
  fullwidth: true

  # Private Use Area characters, custom icon/font glyphs, sometimes abused for spam or ASCII-art walls
  private-use-area: true

  # Standard emoji ranges. Disabled by default since most servers allow emoji in chat.
  emoji: false

  # Restrict messages to an explicit whitelist of unicode scripts (see 'scripts.allowed' below).
  # Disabled by default, only enable this if you want to block non-Latin alphabets entirely,
  # e.g. to prevent Cyrillic/Greek homoglyph impersonation of staff names.
  scripts: false

zalgo:
  # Maximum number of stacked combining marks allowed on a single base character before it's flagged
  max-combining-marks: 2

scripts:
  # Only used if filters.scripts: true
  # Valid names: see java.lang.Character.UnicodeScript (e.g. LATIN, CYRILLIC, GREEK, HAN, ARABIC...)
  # https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Character.UnicodeScript.html
  allowed:
    - LATIN
    - COMMON
    - INHERITED

# https://tchat.tect.host/general/actions
actions:
  - "[MESSAGE] <red>Your message contains disallowed characters.</red>"
```


# Configuration

Configuration file: modules/autobroadcast.yml

## General

```yml
modules:
  # This module sends messages via chat (or performs actions) every few seconds
  #
  # Auto broadcast module loaded from modules/autobroadcast.yml
  auto-broadcast: true
```

* modules.auto-broadcast: Enable/disable the module

***

## Module

#### Options

```yml
options:
  # Seconds between each broadcast entry
  time: 300
```

* options.time: The seconds between each broadcast

#### Broadcast

```yml
broadcasts:
  broadcast1:
    message:
      - "<dark_gray><strikethrough>                              </strikethrough>"
      - "<gradient:#c03afe:#5b03e4><bold>✦ TChat5 ✦</bold></gradient>"
      - "<gray>Welcome back, <white>%player_name%</white></gray>"
      - "<gray>This server is powered by</gray> <gradient:#c03afe:#a72cf8:#8e1ff1:#7411eb:#5b03e4><bold>TChat</bold></gradient>"
      - "<dark_gray><strikethrough>                              </strikethrough>"
    channel: "global"
    permission: "tchat.broadcast.view.broadcast1"
    actions: []
```

* message: The message to be sent via chat, compatible with MiniMessage, legacy colors, PlaceholderAPI, and %center%
* channel: (optional) The channel through which the message will be sent
* permission: (optional) Permission to view the message
* actions: (optional) The actions that will be performed when the message is sent


# Default configuration

```yml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                       autobroadcast.yml                      ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

options:
  # Seconds between each broadcast entry
  time: 300

broadcasts:

  broadcast1:
    # Message lines (supports %center%, &, MiniMessage, and PlaceholderAPI)
    message:
      - "<dark_gray><strikethrough>                              </strikethrough>"
      - "<gradient:#c03afe:#5b03e4><bold>✦ TChat5 ✦</bold></gradient>"
      - "<gray>Welcome back, <white>%player_name%</white></gray>"
      - "<gray>This server is powered by</gray> <gradient:#c03afe:#a72cf8:#8e1ff1:#7411eb:#5b03e4><bold>TChat</bold></gradient>"
      - "<dark_gray><strikethrough>                              </strikethrough>"

    # Channel to send the broadcast through
    channel: "global"

    # Optional. If set, only players with this permission see this broadcast
    permission: "tchat.broadcast.view.broadcast1"

    # Coming soon...
    actions: []

  broadcast2:
    message:
      - "%center%<gradient:#ff4d6d:#ff758f><bold>✦ ANNOUNCEMENT ✦</bold></gradient>"
      - "%center%<gray>Need powerful hosting?</gray>"
      - "%center%<gray>Try</gray> <gradient:#8e2de2:#4a00e0><bold>Tect.host</bold></gradient>"
      - "%center%<gray>High performance Minecraft & VPS hosting</gray>"

    # No channel entry = send the message to global chat

    # No permission entry = visible to all players

    # Coming soon...
    actions: []
```


# Configuration

Configuration file: config.yml

```yml
modules:
  # This module adds a command to block the chat
  #
  # This module does not have a configuration file
  block-chat: true
```

* modules.block-chat: Enable/disable the module


# Configuration

## General

```yml
modules:
  # Allows to block specific commands from being used in chat
  #
  # Blocked commands module loaded from modules/blockedcommands.yml
  blocked-commands: true
```

* modules.blocked-commands: Enable/disable the module

***

## Module

#### Blocked Commands

```yml
# List of commands players cannot use
# Supports commands with or without '/'
#
# If you block "/me" (or "me"), commands like "/me ga" will also
# be blocked, but "/mega" will not
blocked-commands:
  - icanhasbukkit
  - ver
  - about
  - pl
  - plugins
  - help
  - "?"
  - me
  - bukkit:icanhasbukkit
  - bukkit:ver
  - bukkit:about
  - bukkit:pl
  - bukkit:plugins
  - bukkit:help
  - bukkit:?
  - bukkit:me
```

* Here is a list of all blocked commands, you can add or remove as many as you like


# Default configuration

Configuration file: modules/blockedcommands.yml

```yml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                      blockedcommands.yml                     ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# List of commands players cannot use
# Supports commands with or without '/'
#
# If you block "/me" (or "me"), commands like "/me ga" will also
# be blocked, but "/mega" will not
blocked-commands:
  - icanhasbukkit
  - ver
  - about
  - pl
  - plugins
  - help
  - "?"
  - me
  - bukkit:icanhasbukkit
  - bukkit:ver
  - bukkit:about
  - bukkit:pl
  - bukkit:plugins
  - bukkit:help
  - bukkit:?
  - bukkit:me

# Message sent to the player
# Supports MiniMessage tags and legacy & color codes
# Leave empty to block silently (no message shown)
message:
  - "&cYou are not allowed to use that command."
  
# Coming soon...
actions: []
```


# Configuration

This module blocks words based on a configurable list and performs actions when they are blocked.

## General

```yml
modules:
  # Allows you to block or censor words from a list
  # It also detects similar words; for example:
  # If the word "hello" is blocked, "he llo" will also be blocked
  #
  # Blocked words module loaded from modules/blockedwords.yml
  blocked-words: true
```

* modules.blocked-words: Enable/disable the module

***

## Module

#### Action

```yml
# What to do when a blocked word is detected:
# - CENSOR: Replace only the matched characters with censor-char (partial)
# - CENSOR_ALL: Replace the entire message with censor-char repeated
# - BLOCK: Cancel the message entirely
action: CENSOR
```

* CENSOR: It censors ONLY the blocked word, for example:.\
  If you block "hello" and type "hellos," the result will be "\*\*\*\*\*s".
* CENSOR\_ALL: Censor the blocked word and the rest of the word.\
  If you block "hello" and type "hellos," the result will be "\*\*\*\*\*\*".
* BLOCK: Blocks the message when a blocked word is detected and sends a message.

#### Blocked Words

The list of all blocked words


# Command

## Usage

```
/blockedwords <add|remove|list>
```

### Add

```
/blockedwords add <word>
```

### Remove

```
/blockedwords remove <word>
```

### List

```
/blockedwords list
```


# Default configuration

Configuration file: modules/blockedwords.yml

```yml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                       blockedwords.yml                       ║
# ╚══════════════════════════════════════════════════════════════╝

# What to do when a blocked word is detected:
# - CENSOR:  Replace only the matched characters with censor-char (partial)
# - CENSOR_ALL: Replace the entire message with censor-char repeated
# - BLOCK: Cancel the message entirely
action: CENSOR

# Message sent to the player when their message is blocked (only used when action: BLOCK).
# Supports legacy color codes and MiniMessage tags.
# Leave empty to send no message.
block-message:
  - "&cYour message was blocked."

# Character used to replace matched letters (only relevant when action: CENSOR)
censor-char: "*"

# List of words to block.
# Detection is fuzzy: special characters and spaces are ignored,
# and minor typos (up to 1–2 edits depending on word length) are also caught
blocked-words:
  - Arse
  - Ass
  - Asshole
  - Aternos
  - Homosexual
  - Homophobic
  - Racist
  - Gay
  - Lgbt
  - Jew
  - kike
  - Kike
  - Jewish
  - Anti-semitic
  - Chink
  - Muslims
  - Muslim
  - Isis
  - Islamophobe
  - homophobe
  - Bombing
  - Sexyhot
  - Bastard
  - Bitch
  - Fucker
  - Cunt
  - Damn
  - Fuck
  - Goddamn
  - Shit
  - Motherfucker
  - Nigga
  - Nigger
  - Prick
  - Shit
  - Shitass
  - Whore
  - Thot
  - Slut
  - Faggot
  - Dick
  - Pussy
  - Penis
  - Vagina
  - Negro
  - Coon
  - Bitched
  - Sexist
  - Freaking
  - Cock
  - Sucker
  - subnormal
  - anormal
  - Lick
  - Licker
  - Rape
  - ctm
  - Molest
  - Anal
  - Buttrape
  - Coont
  - Cancer
  - Sex
  - sexo
  - Retard
  - Fuckface
  - Dumbass
  - 5h1t
  - 5hit
  - A_s_s
  - a2m
  - a55"
  - amateur
  - anilingus
  - anus
  - ar5e
  - arrse
  - arsehole
  - asses
  - assfucker
  - assfukka
  - assholes
  - assmucus
  - assmunch
  - asswhole
  - autoerotic
  - b00bs
  - b17ch
  - b1tch
  - ballbag
  - ballsack
  - bangbros
  - bareback
  - bastard
  - beastial
  - beastiality
  - bellend
  - bestial
  - bestiality
  - biatch
  - bimbos
  - birdlock
  - bitch
  - bitcher
  - bitchers
  - bitches
  - bitchin
  - bitching
  - bloody
  - blowjob
  - blowjobs
  - blumpkin
  - boiolas
  - bollock
  - bollok
  - boner
  - boob
  - boobs
  - booobs
  - boooobs
  - booooobs
  - booooooobs
  - breasts
  - buceta
  - bugger
  - bum
  - busty
  - butt
  - butthole
  - buttmuch
  - buttplug
  - c0ck
  - c0cksucker
  - carpetmuncher
  - cawk
  - chink
  - choade
  - cipa
  - cl1t
  - clit
  - clitoris
  - clits
  - clusterfuck
  - cnut
  - cock
  - cockface
  - cockhead
  - cockmunch
  - cockmuncher
  - cocks
  - cocksuck
  - cocksucked
  - cocksucker
  - cocksucking
  - cocksucks
  - cocksuka
  - cocksukka
  - cok
  - cokmuncher
  - coksucka
  - coon
  - cornhole
  - cox
  - cum
  - cumdump
  - cummer
  - cumming
  - cums
  - cumshot
  - cunilingus
  - cunillingus
  - cunnilingus
  - cunt
  - cuntbag
  - cuntlick
  - cuntlicker
  - cuntlicking
  - cunts
  - cuntsicle
  - cyalis
  - cyberfuc
  - cyberfuck
  - cyberfucked
  - cyberfucker
  - cyberfuckers
  - cyberfucking
  - d1ck
  - damn
  - dick
  - dickhead
  - dildo
  - dildos
  - dink
  - dinks
  - dirsa
  - dlck
  - doggiestyle
  - doggin
  - dogging
  - donkeyribber
  - doosh
  - duche
  - dyke
  - ejaculate
  - ejaculated
  - ejaculates
  - ejaculating
  - ejaculatings
  - ejaculation
  - ejakulate
  - erotic
  - f_u_c_k
  - f4nny
  - facial
  - fag
  - fagging
  - faggitt
  - faggot
  - faggs
  - fagot
  - fagots
  - fags
  - fanny
  - fannyflaps
  - fannyfucker
  - fanyy
  - fatass
  - fcuk
  - fcuker
  - fcuking
  - feck
  - fecker
  - felching
  - fellate
  - fellatio
  - fingerfuck
  - fingerfucked
  - fingerfucker
  - fingerfuckers
  - fingerfucking
  - fingerfucks
  - fistfuck
  - fistfucked
  - fistfucker
  - fistfuckers
  - fistfucking
  - fistfuckings
  - fistfucks
  - flange
  - fook
  - fooker
  - fuck
  - fucka
  - fucked
  - fucker
  - fuckers
  - fuckhead
  - fuckheads
  - fuckin
  - fucking
  - fuckings
  - fuckingshitmotherfucker
  - fuckme
  - fuckmeat
  - fucks
  - fucktoy
  - fuckwhit
  - fuckwit
  - fudgepacker
  - fuk
  - fuker
  - fukker
  - fukkin
  - fuks
  - fukwhit
  - fukwit
  - fux
  - fux0r
  - gangbang
  - gangbang
  - gangbanged
  - gangbangs
  - gaylord
  - gaysex
  - goatse
  - god
  - goddamn
  - goddamned
  - hardcoresex
  - heshe
  - hoar
  - hoare
  - hoer
  - homo
  - homoerotic
  - hore
  - horniest
  - horny
  - hotsex
  - jackoff
  - jap
  - jerk
  - jism
  - jiz
  - jizm
  - jizz
  - kawk
  - knob
  - knobead
  - knobed
  - knobend
  - knobend
  - knobhead
  - knobjocky
  - knobjokey
  - kock
  - kondum
  - kondums
  - kum
  - kummer
  - kumming
  - kums
  - kunilingus
  - kwif
  - l3itch
  - labia
  - LEn
  - lmao
  - lmfao
  - lmfao
  - lust
  - lusting
  - m0f0"
  - m0fo
  - m45terbate
  - ma5terb8
  - ma5terbate
  - mafugly
  - masochist
  - masterb8
  - masterbat3
  - masterbate
  - masterbation
  - masterbations
  - masturbate
  - mof0
  - mofo
  - mothafuck
  - mothafucka
  - mothafuckas
  - mothafuckaz
  - mothafucked
  - mothafucker
  - mothafuckers
  - mothafuckin
  - mothafucking
  - mothafuckings
  - mothafucks
  - motherfuck
  - motherfucked
  - motherfucker
  - motherfuckers
  - motherfuckin
  - motherfucking
  - motherfuckings
  - motherfuckka
  - motherfucks
  - muff
  - mutha
  - muthafecker
  - muthafuckker
  - muther
  - mutherfucker
  - n1gga
  - n1gger
  - nazi
  - nigg3r
  - nigg4h
  - nigga
  - niggah
  - niggas
  - niggaz
  - nigger
  - niggers
  - nob
  - nobhead
  - nobjocky
  - nobjokey
  - numbnuts
  - nutsack
  - orgasim
  - orgasims
  - orgasm
  - orgasms
  - p0rn
  - pawn
  - pecker
  - penis
  - penisfucker
  - phonesex
  - phuck
  - phuk
  - phuked
  - phuking
  - phukked
  - phukking
  - phuks
  - phuq
  - pigfucker
  - pimpis
  - piss
  - pissed
  - pisser
  - pissers
  - pisses
  - pissflaps
  - pissin
  - pissing
  - pissoff
  - poop
  - porn
  - porno
  - pornography
  - pornos
  - prick
  - pricks
  - pron
  - pube
  - puto
  - puta
  - pusse
  - pussi
  - pussies
  - pussy
  - pussys
  - queaf
  - queer
  - rectum
  - retard
  - rimjaw
  - rimming
  - s_h_i_t
  - sadism
  - sadist
  - sandbar
  - schlong
  - screwing
  - scroat
  - scrote
  - scrotum
  - semen
  - sex
  - sh1t
  - shag
  - shagger
  - shaggin
  - shagging
  - shemale
  - shit
  - shitdick
  - shite
  - shited
  - shitey
  - shitfuck
  - shitfull
  - shithead
  - shiting
  - shitings
  - shits
  - shitted
  - shitter
  - shitters
  - shitting
  - shittings
  - shitty
  - skank
  - slope
  - slut
  - sluts
  - smegma
  - smut
  - snatch
  - spac
  - spunk
  - t1tt1e5
  - t1tties
  - teets
  - teez
  - testical
  - testicle
  - tit
  - titfuck
  - tits
  - titt
  - tittie5
  - tittiefucker
  - titties
  - tittyfuck
  - tittywank
  - titwank
  - tosser
  - turd
  - tw4t
  - twat
  - twathead
  - twatty
  - twunt
  - twunter
  - v14gra
  - v1gra
  - vagina
  - viagra
  - vulva
  - w00se
  - wang
  - wank
  - wanker
  - wanky
  - whoar
  - whore
  - willies
  - wtf
  - xrated
  - xxx

# Coming soon...
actions: []

```


# Configuration

Configuration file: modules/channels.yml

This module translates chat colors based on the user's permissions.

## General

```yaml
modules:
  # This module allows you to create private channels.
  #
  # Channels module loaded from modules/channels.yml
  channels: true
```

* modules.channels: Enable/disable the module.

***

## Module

```yml
  moderation:
    permission: "tchat.channel.mod"
    format: "&8[&bMod&8] &a%tchat_nick% &7> <message>"
    message-mode: 1
    announce-mode: 2
    limit: 10
```

* permission: This is the permission to join and leave the channel\
  \<permission>.send: The permission to use /channel send \<channel> \<message>
* format: The format for the users inside the channel (or using the send command)
* message-mode: This option is used to specify which players should receive messages from the channel
* announce-mode: This option is used to specify which users should receive notifications from the channel (for example, when a user joins the channel)
* limit: The player limit of the channel

#### Message & Announce mode

* 0 -> visible to all online players
* 1 -> visible to players with channel permission
* 2 -> visible only to players who are in the channel (/channel join)
* 3 -> disabled (no one receives the message/announcement)


# Default configuration

```yml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                         channels.yml                         ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# Message / Announce Mode:
# - 0 -> visible to all online players
# - 1 -> visible to players with channel permission
# - 2 -> visible only to players who are in the channel (/channel join)
# - 3 -> disabled (no one receives the message/announcement)
#
# Permissions:
# - <permission> -> join, leave and use the channel
# - <permission>.send ->

channels:

  admin:
    # This permission is to join/leave the channel
    # To use /channel send <message> you need to use tchat.channel.admin.send permission
    permission: "tchat.channel.admin"
    # This format takes precedence over the group and format settings,
    # so it will override any format the user already has
    format: "&8[&cAdmin&8] &a%tchat_nick% &7> <message>"
    message-mode: 2
    announce-mode: 2
    # 0 = no limit
    limit: 0

  moderation:
    permission: "tchat.channel.mod"
    format: "&8[&bMod&8] &a%tchat_nick% &7> <message>"
    message-mode: 1
    announce-mode: 2
    # 10 players limit
    limit: 10

  global:
    permission: "tchat.channel.global"
    format: "&8[&4Global&8] &a%tchat_nick% &7> <message>"
    message-mode: 0
    announce-mode: 0
    # If you don't set a limit, it will be treated as 0 (unlimited)
```


# Configuration

## General

```yaml
modules:
  # This module allows you to create channels between worlds
  #
  # Chat bridge module loaded from modules/chatbridge.yml
  chat-bridge: true
```

* modules.chat-bridge: Enable/disable the module.

***

## Module

Bridges are “groups” of worlds where players can see messages sent between them. For example, the default bridge allows you to see messages only between the “world” and ‘world\_nether’ worlds; players in “world\_the\_end” or any other world can see messages sent between them (if there are no other bridges), but they won’t be able to see messages from players in “world” and “world\_nether.” Players in either of those two worlds will be able to see messages between themselves.

```yaml
bridges:
  bridge1:
    - "world"
    - "world_nether"
```


# Default configuration

Configuration file: modules/chatbridge.yml

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                        chatbridge.yml                        ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

bridges:
  bridge1:
    - "world"
    - "world_nether"
  # bridge2:
  #   - "survival"
  #   - "survival_nether"
  #   - "survival_the_end"
```


# Configuration

Configuration file: modules/chatcooldown.yml

## General

```yaml
modules:
  # This module allows you to set a few seconds between each message from the player.
  #
  # Chat cooldown module loaded from modules/chatcooldown.yml
  chat-cooldown: true
```

* modules.chat-cooldown: Enable/disable the module.

***

## Module

#### Cooldown Seconds

```yaml
# The number of seconds a player must wait between messages.
cooldown-seconds: 3
```

* The seconds between messages


# Default configuration

Configuration file: modules/chatcooldown.yml

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                        chatcooldown.yml                      ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# The number of seconds a player must wait between messages.
cooldown-seconds: 3

# Actions taken when a player types while on cooldown.
# You can use %cooldown_remaining% to display the remaining seconds.
actions:
  - "[MESSAGE] <red>You must wait <yellow>%cooldown_remaining%s</yellow> before you can type again."
```


# Configuration

Configuration file: modules/chatplaceholders/\*.yml

## General

```yaml
modules:
  # Allows players to display custom tags in chat
  #
  # Item tag module loaded from modules/chatplaceholders/chatplaceholders.yml
  chat-placeholders: true
```

* modules.chat-placeholders: Enable/disable the module.

***

## Module

<sub>chatplaceholders.yml</sub>

#### Max replacements per message

This is the maximum number of tags a message can have.

#### Built in

These are the tags that TChat has by default.

### \[ITEM] tag

<sub>itemtag.yml</sub>

#### Trigger

This is the text it will detect in the chat to replace it with the item in your hand.

#### Permission

Permission to use this tag, if it is empty, no permissions are required.

#### Format

This is the format of the text replaced from the trigger

#### Empty hand

Here you can customize the format if the player has nothing in their hand.

### Custom tags

Here you can create your own tags using [TChat actions](/general/actions).

```yaml
tags:
  - trigger: "[pos]"
    permission: ""
    label: "[<green>%player_x% %player_y% %player_z%</green>]"
    actions: []
```

* trigger: Same as in itemtag -> This is the text it will detect in the chat to replace it with the item in your hand.
* permission: The permission to use this tag (empty = available for everyone)
* label: The text that replaces the trigger.
* actions: [Actions](/general/actions) taken when the trigger is detected in the message.


# Default configuration

Configuration file: modules/chatplaceholders/\*.yml

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                     chatplaceholders.yml                     ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# Maximum total tag replacements per message across ALL tags combined.
# 0 = unlimited.
max-replacements-per-message: 5

# Toggle built-in tags individually.
# Each has its own config file inside this folder.
built-in:
  item: true
```

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                        custom-tags.yml                       ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# Define custom tags here. When a player writes the trigger in chat:
#   1. The trigger is replaced in the message by "label" (seen by everyone).
#   2. "actions" are executed for the player who sent the message.

# Fields:
# - trigger -> string to detect in chat (case-insensitive, required)
# - permission -> leave empty to allow everyone (optional)
# - label -> MiniMessage text shown in the message (required)
# - actions -> executed for the player who wrote the message (optional)
#   - https://tchat.tect.host/general/actions

# Examples:
#
# tags:
#   - trigger: "[discord]"
#     permission: ""
#     label: "<click:open_url:'https://discord.gg/yourserver'><hover:show_text:'<gray>Click to join!'>[<#5865F2>Discord</#5865F2>]</hover></click>"
#     actions:
#       - "[MESSAGE] <gray>Discord invite: <aqua>https://discord.gg/yourserver"

tags:
  - trigger: "[pos]"
    permission: ""
    label: "[<green>%player_x% %player_y% %player_z%</green>]"
    actions: []
```

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                          itemtag.yml                         ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# Trigger string matched case-insensitively in chat messages.
trigger: "[item]"

# Permission required to use this tag. Leave empty for everyone.
permission: ""

# Label shown in chat
# Placeholders: <item_name>, <item_count>
# Hover is always the native item tooltip (name, lore, enchantments, etc.)
format: "<aqua><item_name></aqua>"

# What to show when the player holds nothing.
empty-hand:
  enabled: true
  format: "[<gray>Air</gray>]"
```


# Configuration

Configuration file: config.yml

This module translates chat colors based on the user's permissions.

## General

```yaml
modules:
  # Allows to translate colors and formats in chat using permissions
  #
  # This module does not have a configuration file
  colorchat: true
```

* modules.colorchat: Enable/disable the module.


# Configuration

Configuration file: modules/commandcooldown.yml

## General

```yaml
modules:
  # This module allows you to set a few seconds between each command from the player.
  #
  # Command cooldown module loaded from modules/commandcooldown.yml
  command-cooldown: true
```

* modules.command-cooldown: Enable/disable the module.

***

## Module

#### Cooldown Seconds

```yaml
# The number of seconds a player must wait between commands.
cooldown-seconds: 3
```

* The seconds between commands


# Default configuration

Configuration file: modules/commandcooldown.yml

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                       commandcooldown.yml                    ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# The number of seconds a player must wait between commands.
cooldown-seconds: 3

# Actions taken when a player runs a command while on cooldown.
# You can use %cooldown_remaining% to display the remaining seconds.
actions:
  - "[MESSAGE] <red>You must wait <yellow>%cooldown_remaining%s</yellow> before using another command."
```


# Configuration

## General

```yaml
modules:
  # Allows to create custom commands with args, cooldown and actions.
  # The chat reload does not apply to the Custom Commands module,
  # you must restart the server if you make any changes or if you add or remove commands.
  #
  # Custom Commands module loaded from modules/customcommands/*.yml
  custom-commands: true
```

* modules.custom-commands: Enable/disable the module.

***

## Module

#### Name

```yaml
name: heal
```

The primary name of the command.

This is the command players will execute.

### Aliases

```yaml
aliases:
  - healme
```

Alternative names that execute the same command.

***

### Arguments

```yaml
args:
  min: 0
  max: -1
  usage: "/heal"
  usage-actions:
    - "[MESSAGE] <red>Usage: {usage}"
```

Defines how many arguments the command accepts.

#### Min

Minimum number of required arguments.

#### Max

Maximum number of allowed arguments.

Use `-1` to allow unlimited arguments.

#### Usage

Usage message shown to the player through `{usage}`.

#### Usage-actions

Actions executed when the player provides an invalid number of arguments.

***

### Permission

```yaml
# - Remove or leave blank to allow everyone
permission: "tchat.command.heal"
no-permission-actions:
  - "[MESSAGE] <red>You don't have permission to use /heal."
```

Permission required to execute the command.

Remove this option or leave it empty to allow every player to use the command.

### Cooldown

```yaml
cooldown: 30
cooldown-actions:
  - "[MESSAGE] <yellow>You must wait <bold>{remaining}s</bold> before using /heal again."
```

Cooldown in seconds before the player can use the command again.

Set to `0` to disable the cooldown.

### Actions

Check actions [here](/general/actions).

```yaml
# Actions on success
# {arg0} = the destination the player typed
# {args} = all arguments joined by space
# {player} = player name
actions:
  - "[CONSOLE_COMMAND] effect give {player} instant_health 1 255 true"
  - "[MESSAGE] <green>You have been healed!</green>"
  - "[SOUND] entity.player.levelup"
```

### Available placeholders

| Placeholder | Description                                |
| ----------- | ------------------------------------------ |
| `{player}`  | Player executing the command.              |
| `{arg0}`    | First argument.                            |
| `{arg1}`    | Second argument.                           |
| `{arg2}`    | Third argument.                            |
| `{args}`    | All arguments joined into a single string. |


# Configuration

Configuration file: config.yml

This module modifies the style of chat messages for all users.

## General

```yml
modules:
  # Global format module (The group format will continue working even if you disable this module)
  #
  # The formatting module applies to all users, if used in conjunction with the groups module,
  # it will only apply if the user's group does not have formatting enabled
  #
  # Format module loaded from config.yml (do not delete this if you disable the formatting module)
  format: true
```

* modules.format: Enable/disable the full module.

***

## Module

```yml
chat:
  # Global chat format (modules.format)
  # You can use placeholders from the PlaceholderAPI
  # Preferably use MiniMessage colors, although legacy colors (&) will also work
  format: "%luckperms_prefix%&a%player_name% &e>> &7<message>"
```

* chat.format: The global format (supports PlaceholerAPI, MiniMessage and legacy colors).\
  \- Use `<message>` to replace it with the player's message.\
  \- You can use MiniMessage to add Tooltip and hover actions.


# Default configuration

Configuration file: config.yml

```yml
chat:
  # Global chat format (modules.format)
  # You can use placeholders from the PlaceholderAPI
  # Preferably use MiniMessage colors, although legacy colors (&) will also work
  format: "%luckperms_prefix%&a%player_name% &e>> &7<message>"
```


# Configuration

Configuration file: modules/grammar.yml

## General

```yml
modules:
  # Automatically formats chat messages by fixing spacing, capitalization, and punctuation
  #
  # Grammar module loaded from modules/grammar.yml
  grammar: true
```

* modules.grammar: Enable/disable the full module

***

## Module

#### Trim Spaces

```yaml
# Collapses multiple consecutive spaces into a single one and trims
# leading/trailing whitespace from the message.
trim-spaces:
  enabled: true
```

Collapses multiple consecutive spaces into a single space and removes leading/trailing whitespace.

#### Capitalization

```yaml
# Capitalizes the first letters of the message.
# Example: "hello" -> "Hello" (with letters: 1)
cap:
  enabled: true
  # Number of letters to convert to uppercase, starting from the beginning.
  letters: 1
  # Minimum message length required to trigger this function.
  min-characters: 0
```

Capitalizes the first letters of the message.

#### Sentence Case

```yaml
# Capitalizes the first letter after a sentence-ending punctuation mark
# (., ! or ?) followed by a space.
sentence-case:
  enabled: true
  # Minimum message length required to trigger this function.
  min-characters: 0
```

Capitalizes the first letter after a sentence-ending punctuation mark (`.`, `!` or `?`) followed by a space.

#### Final Dot

```yaml
# Appends a final character to the message if it doesn't already end
# with one of the ignored endings below.
final-dot:
  enabled: true
  # You can customize this, you can use any other character, but
  # I recommend leaving it as a single dot.
  character: "."
  # Minimum message length required to trigger this function.
  min-characters: 0
  # Endings that prevent the final character from being appended
  # (only the last character of the message is checked).
  ignore-endings:
    - "."
    - "!"
    - "?"
    - ","
    - ";"
    - ":"
    - ")"
    - "]"
    - "}"
    - "\""
    - "'"
```

Appends a character to the end of the message if it does not already end with one of the ignored endings.


# Default configuration

Configuration file: modules/grammar.yml

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                          grammar.yml                         ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# Collapses multiple consecutive spaces into a single one and trims
# leading/trailing whitespace from the message.
trim-spaces:
  enabled: true

# Capitalizes the first letters of the message.
# Example: "hello" -> "Hello" (with letters: 1)
cap:
  enabled: true
  # Number of letters to convert to uppercase, starting from the beginning.
  letters: 1
  # Minimum message length required to trigger this function.
  min-characters: 0

# Capitalizes the first letter after a sentence-ending punctuation mark
# (., ! or ?) followed by a space.
sentence-case:
  enabled: true
  # Minimum message length required to trigger this function.
  min-characters: 0

# Appends a final character to the message if it doesn't already end
# with one of the ignored endings below.
final-dot:
  enabled: true
  # You can customize this, you can use any other character, but
  # I recommend leaving it as a single dot.
  character: "."
  # Minimum message length required to trigger this function.
  min-characters: 0
  # Endings that prevent the final character from being appended
  # (only the last character of the message is checked).
  ignore-endings:
    - "."
    - "!"
    - "?"
    - ","
    - ";"
    - ":"
    - ")"
    - "]"
    - "}"
    - "\""
    - "'"
```


# Configuration

Configuration file: modules/groups.yml

## General

```yml
modules:
  # Allows you to configure prefixes, suffixes, formats, and other options by permission-based groups
  #
  # Group module loaded from modules/groups.yml
  group: true
```

* modules.group: Enable/disable the full module

***

## Module

Example group:

```yml
groups:
  example: #<-- Group name
    permission: tchat.group.example #<-- Example permission
    priority: 1 #<-- Group priority
    prefix: "" #<-- This group don't have a prefix
    suffix: "" #<-- This group don't have a suffix
    format: "%tchat_prefix% <gray> %tchat_nick% </gray> <yellow>></yellow> <white><message></white>" #<-- Example format
```

* groups.example: The group name (id).
* groups.example.permission: The group permission (you can use any other permission, you don't need to use tchat.group.X).
* groups.example.priority: The priority (1 > 2), If a user has permission for the owner group and also has permission for the admin group, but owner has priority 1 and admin has priority 2, the user will have the owner group.
* groups.example.prefix: The group prefix (%tchat\_prefix%), to disable it, leave the section empty.
* groups.example.suffix: The group suffix (%tchat\_suffix%), to disable it, leave the section empty.
* groups.example.format: The group format, to disable it, leave the section empty (So that group will use the global format from config.yml).\
  \- Use `<message>` to replace it with the player's message.\
  \- You can use MiniMessage to add Tooltip and hover actions.


# Permissions

## Group permissions (modules/groups.yml)

All groups have their own permission (two groups cannot have the same permission) except the default group, you can change the name of this group but it is not necessary that it has a permission (it can have it, but if the player has no group, it will take that group whether it has the permission or not).


# Default configuration

Configuration file: modules/groups.yml

```yml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                          groups.yml                          ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

groups:

  op:
    permission: tchat.group.op
    # Lower number means higher priority
    priority: 1
    prefix: "&4&lOWNER"
    suffix: ""
    # If empty, this group format is considered disabled
    # You can use placeholders from the PlaceholderAPI
    # Preferably use MiniMessage colors, although legacy colors (&) will also work
    format: "%tchat_prefix% <reset><hover:show_text:'<gray>Player: <yellow>%tchat_nick%'><white>%tchat_nick%</white></hover> <yellow>></yellow> <white><message></white>"

  admin:
    permission: tchat.group.admin
    # Lower number means higher priority
    priority: 2
    prefix: "&c&lADMIN"
    suffix: ""
    # If empty, this group format is considered disabled
    # You can use placeholders from the PlaceholderAPI
    # Preferably use MiniMessage colors, although legacy colors (&) will also work
    format: "%tchat_prefix% <reset><hover:show_text:'<gray>Player: <yellow>%tchat_nick%'><white>%tchat_nick%</white></hover> <yellow>></yellow> <white><message></white>"

```


# Configuration

Configuration file: modules/invsee.yml

## General

```yml
modules:
  # Allows to inspect other player inventories
  #
  # Invsee module loaded from modules/invsee.yml
  invsee: false
```

* modules.invsee: Enable/disable the full module

***

## Module

#### Title

The title of the menu.

#### Filter

This item is placed in empty slots (excluding the inventory, armor, and hands).

#### Close button

The button to close the menu in slot 44.


# Default configuration

Configuration file: modules/invsee.yml

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                          invsee.yml                          ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

# Title of the inventory GUI (supports MiniMessage format)
title: "<gray><player>'s inventory</gray>"

# Item shown in empty/unused slots
filler:
  enabled: true
  material: GRAY_STAINED_GLASS_PANE
  name: " "
  lore: []

# Close button, always placed in the last free slot (slot 44)
close-button:
  enabled: true
  material: BARRIER
  name: "<red>Close</red>"
  lore:
    - "<gray>Click to close this menu.</gray>"

```


# Configuration

## General

```yml
modules:
  # Allows to change your nickname
  #
  # This module does not have a configuration file
  nick: true
```

* modules.nick: Enable/disable the module


# Command

## Change

Change your own nick:

```
/nick <nick>
```

Change other user nick:

```
/nick <nick> <player>
```

## Remove

Remove your nick:

```
/nick off
```

Remove other user nick:

```
/nick off <player>
```


# Configuration

Configuration file: config.yml

## General

```yml
modules:
  # Send a message to the admins via chat when the plugin isn't up to date
  #
  # This module does not have a configuration file
  update-notify: true
```

* modules.update-notify: Enable/disable the full module\
  If the module is enabled, when an update is available it will notify administrators when they join the server and also display a message in the console when the server starts.


# Configuration

Configuration file: modules/worlds.yml

## General

```yml
modules:
  # This module allows you to use local chats (radius)
  # It also lets you block chat by world
  #
  # Worlds module loaded from modules/worlds.yml
  worlds: true
```

* modules.worlds: Enable/disable the full module.

***

## Module

```yaml
worlds:

  world:
    chat-enabled: true
    chat-radius:
      radius: 0
      bypass:
        char: "!"
```

* worlds.world.chat-enabled: Enable/disable the chat in the world "world"
* worlds.world.chat-radius.radius: The radius within which players must be located to see each other's messages (0 = disable)
* worlds.world.chat-radius.bypass.char: The character that players must enter in the chat so that the message is sent globally, bypassing the chat radius


# Default configuration

Configuration file: modules/worlds.yml

```yaml
# ╔══════════════════════════════════════════════════════════════╗
# ║                             TChat                            ║
# ║                      tect.host | by Alex                     ║
# ║                                                              ║
# ║                          worlds.yml                          ║
# ╚══════════════════════════════════════════════════════════════╝

# DON'T TOUCH THIS!
config-version: 0

worlds:

  world:
    chat-enabled: true
    chat-radius:
      radius: 0
      bypass:
        char: "!"

  world_nether:
    chat-enabled: true
    chat-radius:
      radius: 0
      bypass:
        char: "!"

  world_the_end:
    chat-enabled: true
    chat-radius:
      radius: 0
      bypass:
        char: "!"

```


