Перейти к содержимому
Mineforgian

[ABANDONED] SimpleChat - Chat mod for Fabric servers

A small mod for a customizable chat, with the most simple settings

Загрузки
2K
Подписчики
12
Обновлён
1 марта 2022 г.
Лицензия
MIT

Опубликован 5 мая 2021 г.

SimpleChat

Temporary stop of support

A simple chat mod for your server.

The current supported version of the mod is: https://modrinth.com/mod/simplechatfork❗

Works even in a single player game.

issues license

simplechat

Requires the Fabric API!

❗Version 1.17 requires Java 16 to work❗

Features

  • Global and local chat (you can turn it off)
  • Color chat (you can turn it off)
  • Reloading the configuration with the command
  • For developers: Player chat event

Imgur

Configuration

The configuration is located in <game or server directory>/config/simplechat.json.

Name Description Type
enable_chat_mod Enables (true) or disables (false) chat handling by the mod. boolean
enable_global_chat Enables (true) or disables (false) the global chat. boolean
enable_chat_colors Enables (true) or disables (false) the use of color codes in the chat. boolean
local_chat_format Defines the appearance of the local chat. String
global_chat_format Defines the appearance of the global chat. String
chat_range Specifies the distance after which local chat messages will not be visible (if global chat is enabled). int
{
  "enable_chat_mod": true,
  "enable_global_chat": false,
  "enable_chat_colors": false,
  "local_chat_format": "%player% > &7%message%",
  "global_chat_format": "&8[&bG&8] &r%player% > &e%message%",
  "chat_range": 100
}

You can use the placeholder %player% to specify the player's nickname and the placeholder %message% to specify their message in the chat.

You can reload the configuration without restarting the server or the game using the /simplechat command (requires permission level 1 or more).

API

If you are a developer, you can use an event called when a player writes something to the chat.

Look me.vetustus.server.simplechat.api.event.PlayerChatCallback. To control the behavior, use the ChatMessage subclass, which can be used to cancel sending a message or change it.

Example:

/**
 * Prohibits players from writing messages by canceling an event.
 */
PlayerChatCallback.EVENT.register((player, message) -> {
  PlayerChatCallback.ChatMessage chatMessage = new PlayerChatCallback.ChatMessage(player, message);
  chatMessage.setCancelled(true);
  return chatMessage;
});

License

The MIT license is used.

Ченджлог

1.3.0Релиз1.18.2 · 1 марта 2022 г.
  • Update to 1.18.2
1.2.1Релиз1.18, 1.18.1 · 16 февраля 2022 г.
  • Update to 1.18.1. Thanks to @braunly
1.2.0Релиз1.18 · 4 февраля 2022 г.
  • Updated to 1.18!🥳🎉 Thanks to @AzureDoom
  • Fixed a bug: the configuration file may not have been created at startup

Full Changelog: https://github.com/rantuhin/SimpleChat/compare/1.1.1...1.2.0

1.1.1Релиз1.17 · 12 июня 2021 г.
  • Fixed a bug: player names are not displayed when players are on a team (#2)
1.0.3Релиз1.16.5 · 12 июня 2021 г.
  • Fixed a bug: player names are not displayed when players are on a team (#2)
  • Added a mod icon
  • Added contact information
1.1.0Релиз1.17 · 9 июня 2021 г.

Changes:

There may be errors or bugs, please create an issue.

❗This version requires Java 16 to work❗

1.0.2Релиз1.16.5 · 7 июня 2021 г.

Fixed #1 - chat is not logged in to the console.

1.0.1Релиз1.16.5 · 7 мая 2021 г.
  • Code cleanup completed
  • Fixed possible bugs
  • Added the ability to disable chat interception by the mod if the mod is used as a library

Add the value "enable_chat_mod": true to your configuration file, or delete the file so that the mod creates a new one.

This value indicates whether the chat will be handled by the mod. Turn it off if you use the mod as a library or you have another mod that handles chat.

Комментарии

Загружаем…