Geyser Sanitizer 图标

Geyser Sanitizer

作者:rebot | 分类:模组

价格:0 墨喵币 下载量:0 点赞:0 版本 0.3.1
本资源为搬运资源,原资源地址: https://modrinth.com/mod/geyser-sanitizer
资源信息

Minecraft 版本: 1.21.11

平台: paper spigot

标签: library utility

资源介绍

Description

GeyserSanitizer is a Spigot/Paper plugin designed to sanitize text components sent to Bedrock players, preventing client crashes or display issues that can arise from certain unsupported text features. It specifically targets and modifies chat messages, system messages, and team-related text (nametags, prefixes, suffixes) to ensure compatibility with Bedrock clients connected via GeyserMC/Floodgate.

Features

  • Chat Message Sanitization: Intercepts and sanitizes outgoing chat messages.
  • System Message Sanitization: Intercepts and sanitizes outgoing system messages.
  • Team Text Sanitization: Cleans nametags, prefixes, and suffixes sent as part of team updates.
  • Bedrock Player Detection: Utilizes Floodgate API to selectively apply sanitization only to Bedrock players.
  • Icon/Head Icon Removal: Removes JSON components containing 'atlas', 'sprite', 'hat', or 'player' keys, which are known to cause issues on Bedrock clients.

Dependencies

This plugin requires the following to function correctly:

  • PacketEvents: Used for intercepting and modifying network packets.
  • Floodgate: Used to identify Bedrock players.

How It Works

The plugin registers a PacketInterceptor listener with PacketEvents. When a server sends certain packets (CHAT_MESSAGE, SYSTEM_CHAT_MESSAGE, TEAMS), the interceptor checks if the recipient is a Bedrock player (using Floodgate). If so, it sanitizes the net.kyori.adventure.text.Component messages by removing JSON structures that contain problematic keys (like "atlas", "sprite", "hat", "player") before the packet is sent to the client. This prevents unsupported features from reaching the Bedrock client and causing issues.

下载太慢?试试 墨喵加速站,支持 Modrinth 和外网直链高速下载! 用的人越多,下载的越快!
下载与版本
评论(0)
登录 后发表评论。

暂无评论,抢个沙发吧~

举报此资源

请登录后举报

🔥 相关推荐
Undertale Weapons

价格:0 墨喵币
下载量:0

查看详情
TNT-Head Creepers

价格:0 墨喵币
下载量:0

查看详情
TerraCraft: Confluence + Calamity

价格:0 墨喵币
下载量:0

查看详情
Invisible viewing mode

价格:0 墨喵币
下载量:0

查看详情