FamilyFriendly 插件
一款 Minecraft 插件,通过过滤不当词汇、链接和垃圾信息,并提供完整的审核与警告系统,确保聊天体验的安全性与适龄性。
功能特性
- 年龄验证系统(玩家首次加入时必须设置年龄)
- 未成年人保护: 仅对未成年玩家的聊天进行过滤,若发送被屏蔽的词汇,将会收到警告/禁言/踢出/封禁处理
- 成年人自由聊天: 成年人可以看到并发送未过滤的聊天内容,但仍需接受垃圾信息和链接的审核限制
- 私聊保护: 如果成年人向未成年玩家发送包含被屏蔽词汇的私聊消息,该消息将对未成年接收者进行过滤,并向成年人发出警告/升级处罚
- 禁言与影子禁言相互独立: 如果玩家被禁言,则完全无法聊天;如果被影子禁言,其消息仅对自己可见。
- 基于年龄的聊天过滤(包括被屏蔽的词汇、链接和服务器 IP)
- 可配置的被屏蔽词汇列表
- 基于权限的链接绕过功能
- 私聊过滤(使用与公共聊天相同的过滤规则)
- 首次加入时自动提示设置年龄并锁定移动
- 可配置的替换字符和警告消息
- 垃圾信息防护,具有独立的升级机制(警告 → 禁言 → 踢出)
- 禁言、解除禁言及定时禁言命令(支持简短别名)
- 持久化警告系统(常规警告和垃圾信息警告在重启后依然保存)
- 升级处罚系统:针对严重违规行为,按顺序执行警告 → 禁言 → 踢出 → 封禁(仅限未成年人,但向未成年人发送私聊违规除外)
- 垃圾信息独立升级机制
- 管理员重置警告和垃圾信息警告的命令
- 查看任意玩家的警告记录
- 增强的日志系统
依赖要求
- Minecraft Spigot/Paper 1.21.X
安装方法
- 下载插件的最新版本 jar 文件
- 将 jar 文件放入服务器的
plugins 文件夹中
- 重启服务器
配置文件
- config.yml:所有设置、阈值、持续时间和权限配置
- blockedwords.yml:被屏蔽词汇列表
- messages.yml:所有面向用户的消息(可自定义)
- players.yml:存储玩家年龄、警告记录和垃圾信息警告记录
主要命令
/age <age> — 设置或更新你的年龄
/mute <player> <duration> 或 /ffmute <player> <duration> — 临时禁言某玩家
/unmute <player> 或 /ffunmute <player> — 提前解除某玩家的禁言状态
/resetwarnings <player> 或 /ffresetwarnings <player> — 重置某玩家的一般警告计数
/resetspamwarnings <player> 或 /ffresetspamwarnings <player> — 重置某玩家的垃圾信息警告计数
/familyfriendly reload 或 /ff reload — 重新加载插件配置
/familyfriendly viewwarn <player> 或 /ff viewwarn <player> — 查看某玩家的一般警告和垃圾信息警告
工作人员提示: 所有审核命令均支持简短别名(例如 /mute、/unmute、/resetwarnings、/resetspamwarnings 及其 /ff... 版本),以便快速访问。
工作原理
- 首次加入: 玩家在聊天或移动前必须设置年龄。
- 聊天过滤: 未成年玩家的发言会被过滤掉被屏蔽的词汇和链接。成年人可以看到并发送未过滤的聊天内容,但仍需接受垃圾信息和链接的审核限制。
- 私聊保护: 如果成年人向未成年玩家发送包含被屏蔽词汇的私聊消息,该消息将对未成年接收者进行过滤,并向成年人发出警告/升级处罚。
- 禁言与影子禁言:
- 如果玩家被禁言,他们将完全无法聊天,并会看到一条禁言提示消息。
- 如果玩家被影子禁言,其消息仅对自己可见(他们不会收到通知)。
- 这两种效果互不重叠或冲突;禁言始终优先于影子禁言。
- 垃圾信息防护: 重复发送消息会触发独立的警告/禁言/踢出系统(垃圾信息违规不会导致封禁)。
- 升级处罚: 一般违规行为(如辱骂、发送链接)会从警告逐步升级为禁言、踢出,最终封禁(所有步骤均可配置,仅限未成年人,但向未成年人发送私聊违规除外)。
- 警告记录: 所有警告都会被保存并在重启后保留。管理员可以重置或查看任何玩家的警告记录。
权限说明
所有权限均通过 LuckPerms(或你选择的权限插件)进行管理。根据需要分配以下权限:
familyfriendly.age:允许玩家设置年龄
familyfriendly.reload:允许重新加载插件配置
familyfriendly.link:允许玩家分享链接和服务器 IP
familyfriendly.op:绕过所有 FamilyFriendly 限制
familyfriendly.mute:允许 Moderator 禁言玩家
familyfriendly.unmute:允许解除玩家禁言
familyfriendly.resetwarnings:允许重置一般警告
familyfriendly.resetspamwarnings:允许重置垃圾信息警告
familyfriendly.viewwarns:允许查看警告计数
LuckPerms 使用示例
lp user <player> permission set familyfriendly.mute true
lp group staff permission set familyfriendly.viewwarns true
故障排除
- 如果玩家无法设置年龄:请确保插件在 plugins 文件夹中具有写入权限
- 如果聊天过滤未生效:请检查 config.yml 和 blockedwords.yml
- 如果私聊未被过滤:请确认玩家是否已设置年龄
- 如果配置更改未生效:请使用
/familyfriendly reload 重新加载设置
日志记录
- 所有聊天和私聊消息都会记录到服务器控制台
- 被屏蔽和过滤的消息会附带警告信息进行记录
许可证
版权所有
FamilyFriendly Plugin
A Minecraft plugin that ensures a safe and age-appropriate chat experience by filtering inappropriate words, links, and spam, with a full moderation and warning system.
Features
- Age verification system (players must set age on first join)
- Underage players are protected: Only underage players have their chat filtered and are warned/muted/kicked/banned for blocked words
- Adults chat freely: Adults see and send unfiltered chat, but are still subject to spam and link moderation
- Private message protection: If an adult sends a private message with blocked words to an underage player, the message is filtered for the underage recipient and the adult is warned/escalated
- Mute and shadow mute are separate: If a player is muted, they cannot chat at all. If shadow muted, their messages are only visible to themselves.
- Age-based chat filtering (blocked words, links, and server IPs)
- Configurable blocked words list
- Permission-based link bypass
- Private message filtering (with same filtering as public chat)
- Automatic age prompt and movement lock on first join
- Configurable replacement characters and warning messages
- Spam protection with separate escalation (warn → mute → kick)
- Mute, unmute, and timed mute commands (with short aliases)
- Persistent warning system (general and spam warnings saved across restarts)
- Escalation system: warn → mute → kick → ban for severe offenses (underage only, except for private messages to underage)
- Separate escalation for spam
- Admin commands to reset warnings and spam warnings
- View warnings for any player
- Enhanced logging system
Requirements
- Minecraft Spigot/Paper 1.21.X
Installation
- Download the latest version of the plugin jar file
- Place the jar file in your server's
plugins folder
- Restart your server
Configuration Files
- config.yml: All settings, thresholds, durations, and permissions
- blockedwords.yml: The list of blocked words
- messages.yml: All user-facing messages (customizable)
- players.yml: Stores player ages, warnings, and spam warnings
Main Commands
/age <age> — Set or update your age
/mute <player> <duration> or /ffmute <player> <duration> — Temporarily mute a player
/unmute <player> or /ffunmute <player> — Unmute a player early
/resetwarnings <player> or /ffresetwarnings <player> — Reset a player's general warning count
/resetspamwarnings <player> or /ffresetspamwarnings <player> — Reset a player's spam warning count
/familyfriendly reload or /ff reload — Reload plugin configuration
/familyfriendly viewwarn <player> or /ff viewwarn <player> — View a player's general and spam warnings
Tip for staff: All moderation commands have short aliases (e.g., /mute, /unmute, /resetwarnings, /resetspamwarnings, and their /ff... versions) for quick access.
How It Works
- First join: Players must set their age before chatting or moving.
- Chat filtering: Underage players have messages filtered for blocked words and links. Adults see and send unfiltered chat, but are still subject to spam and link moderation.
- Private message protection: If an adult sends a private message with blocked words to an underage player, the message is filtered for the underage recipient and the adult is warned/escalated.
- Mute and shadow mute:
- If a player is muted, they cannot chat at all and see a mute message.
- If a player is shadow muted, their messages are only visible to themselves (they are not notified).
- The two effects never overlap or conflict; mute always takes precedence.
- Spam protection: Repeated messages trigger a separate warning/mute/kick system (never bans for spam).
- Escalation: General offenses (cursing, links) escalate from warning to mute, kick, and finally ban (all configurable, underage only, except for private messages to underage).
- Warnings: All warnings are saved and persist across restarts. Admins can reset or view warnings for any player.
Permissions
All permissions are managed via LuckPerms (or your permissions plugin of choice). Assign as needed:
familyfriendly.age: Allows players to set their age
familyfriendly.reload: Allows reloading the plugin configuration
familyfriendly.link: Allows players to share links and server IPs
familyfriendly.op: Bypass all FamilyFriendly restrictions
familyfriendly.mute: Allows moderators to mute players
familyfriendly.unmute: Allows unmuting players
familyfriendly.resetwarnings: Allows resetting general warnings
familyfriendly.resetspamwarnings: Allows resetting spam warnings
familyfriendly.viewwarns: Allows viewing warning counts
Example LuckPerms Usage
lp user <player> permission set familyfriendly.mute true
lp group staff permission set familyfriendly.viewwarns true
Troubleshooting
- If players can't set their age: Ensure the plugin has write permissions in the plugins folder
- If chat filtering isn't working: Check config.yml and blockedwords.yml
- If private messages aren't being filtered: Check if players have set their age
- If configuration changes aren't applying: Use
/familyfriendly reload to reload the settings
Logging
- All chat and private messages are logged to the server console
- Blocked and filtered messages are logged with warnings
License
All Rights Reserved
评论 0
登录后参与评分
还没有评论,来抢沙发吧