MonitoringMinecraft MonitoringMinecraft

SyRedEnvelope

Плагин PaperPurpur

Плагин красных конвертов для серверов Майнкрафт.

156 скачиваний 2 подписчика
Оцените первым

SyExtract

A red envelope plugin for Minecraft Paper/Purpur 1.21 with Vault economy support.

Features

  • Create red envelopes (set name, amount, quantity)
  • Each red envelope has a unique numeric ID starting from 1 (e.g., 1, 2, 3)
  • GUI interface for viewing and claiming red envelopes
  • New "Create Red Envelope" button in GUI — click it and type name, amount, and count in chat
  • BossBar progress bar displayed at the top of the screen after creating a red envelope, showing remaining count in real time
  • Automatic notification to the sender when someone claims their red envelope (includes claimer name, envelope name, amount, and currency name)
  • Configurable tax-free threshold: red envelopes with total amount less than 10000 are tax-free; 2% tax for amounts of 10000 or more
  • If a red envelope is not fully claimed 1 minute after creation, a clickable reminder is sent to online players who haven't claimed it
  • Claim buttons in broadcast and reminder messages are now truly clickable
  • Multi-language support (简体中文/English)
  • Vault economy system support
  • Configurable fee system
  • Player ban system (restrict sending/claiming red envelopes)
  • Red envelope expiration settings
  • Unclaimed amounts are automatically refunded when red envelopes expire
  • Red envelope data is fully preserved after server restart (including amount distribution and claim records)
  • Highly configurable

Requirements

  • Minecraft Server: Paper/Purpur 1.21
  • Java: 17 or higher
  • Dependencies: Vault + any economy plugin (e.g., EssentialsX)

Commands

Command Permission Description
/sye create <name> <amount> <count> syextract.create Create a red envelope
/sye open syextract.open Open the red envelope GUI
/sye broadcast <id> syextract.broadcast Broadcast a red envelope to all players
/sye claim <id> syextract.claim Claim a specific red envelope by ID
/sye ban <player> <time> syextract.ban Ban a player
/sye unban <player> syextract.unban Unban a player
/sye reload syextract.reload Reload configuration

Command Aliases

  • createc
  • openo
  • broadcastbr
  • claimcl
  • banb
  • unbanu
  • reloadr

Time Format

Ban duration supports the following formats:

  • 1h - 1 hour
  • 1d - 1 day
  • 1w - 1 week
  • 30d - 30 days

Permissions

Permission Default Description
syextract.use true Basic usage permission
syextract.create true Create red envelope permission
syextract.open true Open GUI permission
syextract.claim true Claim red envelope permission
syextract.broadcast true Broadcast red envelope permission
syextract.ban op Ban player permission
syextract.unban op Unban player permission
syextract.reload op Reload configuration permission
syextract.admin op All admin permissions

Configuration

config.yml

# Language Settings
# Available values: zh (简体中文), en (English)
language: zh

# Red envelope settings
red-envelope:
  # Default claim duration (hours)
  default-expire-hours: 24
  # Minimum red envelope amount
  min-amount: 1.0
  # Minimum red envelope count
  min-count: 1
  # Maximum red envelope count
  max-count: 100

# Fee settings (charged when creating)
fee:
  enabled: true
  percentage: 0.05
  min-fee: 1.0

# Tax settings (charged when claiming)
tax:
  # Tax-free threshold: red envelopes with total amount below this are tax-free
  threshold: 10000
  # Tax rate: applied when total amount is at or above the threshold
  percentage: 0.02

# Economy settings
economy:
  # Currency name (used when Vault does not provide one)
  currency-name: "Coins"

# Reminder settings
reminder:
  # Seconds after creation to send unclaimed reminder (default: 60)
  delay-seconds: 60

# GUI settings
gui:
  item-material: "SUNFLOWER"

# Broadcast message settings
broadcast:
  envelope-completed: "&6&l🎉 Red envelope &e{name} &7has been fully claimed..."

Language Files

The plugin supports multi-language through language files located in plugins/SyExtract/lang/:

  • zh.yml - 简体中文 (default)
  • en.yml - English

You can customize all messages in these files. To switch language, change the language option in config.yml.

Data Storage

The plugin generates the following data files in the plugins/SyExtract/ directory:

  • envelopes.yml - Red envelope data (including amount distribution and claim records)
  • bans.yml - Ban data
  • lang/ - Language files (auto-generated)

Usage Examples

  1. Create a red envelope via command

    /sye create HappyNewYear 1000 10
    

    Create a red envelope named "HappyNewYear" with a total of 1000 coins divided into 10 shares. The system will display the red envelope ID upon successful creation.

  2. Create a red envelope via GUI

    /sye open
    

    Open the GUI and click the "Create Red Envelope" button (nether star icon) at the bottom. Then type the name, amount, and count in chat one by one.

  3. Open GUI to claim red envelopes

    /sye open
    

    The GUI can be opened even when no red envelopes are available.

  4. Broadcast a red envelope

    /sye broadcast 1
    

    Broadcast the red envelope with ID "1" to all online players. Players can click the "[Claim Now]" button in the chat to claim it.

  5. Claim a specific red envelope

    /sye claim 1
    

    Directly claim the red envelope with ID "1".

  6. Ban a player

    /sye ban PlayerName 7d
    

    Ban a player for 7 days, preventing them from sending and claiming red envelopes.

Notes

  1. Creating a red envelope deducts the envelope amount + fee
  2. Red envelopes use the "line-cutting" random distribution algorithm — each person has an equal probability of receiving any amount, so there is no advantage to claiming first
  3. Expired unclaimed red envelopes will be automatically refunded to the sender
  4. Each player can only claim the same red envelope once
  5. Each red envelope has a unique numeric ID for easy sharing and claiming
  6. When a red envelope's total amount reaches the tax-free threshold (default 10000), claimed amounts are subject to tax
  7. Red envelope data is fully preserved after server restart, including individual amounts and claim records
  8. If a red envelope is not fully claimed 1 minute after creation, the system automatically reminds online players who haven't claimed it

Changelog

v1.5.0

  • Fixed red envelope amount distribution algorithm: switched to the "line-cutting" method to ensure everyone has an equal probability of receiving any amount — no longer does the first claimer get the largest amount
  • Fixed a bug where red envelope amounts were regenerated after server restart, causing distribution errors (amounts are now saved and loaded properly)
  • Added "Create Red Envelope" button in GUI — click it and type name, amount, and count in chat
  • Added BossBar progress bar at the top of the screen after creating a red envelope, showing remaining count in real time
  • Added automatic notification to the sender when someone claims their red envelope (includes claimer name, envelope name, amount, and currency name)
  • Added tax system: configurable tax-free threshold (default 10000) and tax rate (default 2%) in config.yml
  • Added 1-minute unclaimed reminder: sends a clickable reminder message to online players who haven't claimed the red envelope
  • Broadcast and reminder messages now have truly clickable claim buttons
  • Fixed a bug where GUI slot mappings conflicted when multiple players opened the GUI simultaneously
  • Fixed a bug where the sender's name showed as "Unknown" when claiming the last red envelope
  • Added a periodic cleanup task for expired red envelopes
  • Currency name is now automatically retrieved from Vault, with a configurable fallback in config.yml

v1.4.0

  • Added multi-language support (简体中文/English)
  • Language files are now stored in lang/ folder
  • All messages can be customized through language files
  • Added language option in config.yml

v1.3.0

  • Added notification when red envelope is fully claimed
  • Shows the luckiest player (hand king) who got the highest amount
  • Added broadcast.envelope-completed message configuration

v1.2.0

  • Fixed broadcast message not found issue (success.broadcast)
  • Fixed clickable claim button in broadcast messages
  • Changed red envelope ID from random 6-character to sequential numeric ID starting from 1

v1.1.0

  • Added unique ID for each red envelope
  • Added automatic refund for expired unclaimed red envelopes
  • Added /sye broadcast command to broadcast red envelopes
  • Added /sye claim command to claim by ID
  • GUI can now be opened even when no red envelopes are available
  • Updated to Java 17 compatibility

v1.0.0

  • Initial release

Author

SyExtract

一个适用于 Minecraft Paper/Purpur 1.21 的红包插件,支持 Vault 经济系统。

功能特性

  • 创建红包(设置名称、金额、数量)
  • 每个红包拥有从1开始的唯一数字ID(如1、2、3)
  • GUI界面查看和领取红包
  • GUI中新增"创建红包"按钮,点击后在聊天框依次输入名称、金额、个数即可创建
  • 创建红包后在屏幕上方显示BossBar进度条,实时显示剩余个数
  • 有人领取红包时,自动通知红包发放者(包含领取者名称、红包名称、金额、货币名称)
  • 可配置免税界限:红包总额小于10000免税,大于等于10000收2%税
  • 红包创建1分钟后若未领完,自动给未领取的在线玩家发送可点击的提醒消息
  • 广播消息和提醒消息中的领取按钮可点击直接领取
  • 多语言支持(简体中文/English)
  • Vault经济系统支持
  • 可配置的手续费系统
  • 玩家封禁系统(限制发放/领取红包)
  • 红包过期设置
  • 过期未领取的红包金额自动退还给发放者
  • 服务器重启后红包数据完整保留(包括金额分配和领取记录)
  • 高度可配置

运行要求

  • Minecraft服务端:Paper/Purpur 1.21
  • Java:17或更高版本
  • 依赖:Vault + 任意经济插件(如EssentialsX)

命令

命令 权限 说明
/sye create <名称> <金额> <数量> syextract.create 创建红包
/sye open syextract.open 打开红包GUI
/sye broadcast <红包ID> syextract.broadcast 广播红包给所有在线玩家
/sye claim <红包ID> syextract.claim 领取指定ID的红包
/sye ban <玩家> <时间> syextract.ban 封禁玩家
/sye unban <玩家> syextract.unban 解封玩家
/sye reload syextract.reload 重载配置

命令别名

  • createc
  • openo
  • broadcastbr
  • claimcl
  • banb
  • unbanu
  • reloadr

时间格式

封禁时长支持以下格式:

  • 1h - 1小时
  • 1d - 1天
  • 1w - 1周
  • 30d - 30天

权限

权限 默认 说明
syextract.use true 基本使用权限
syextract.create true 创建红包权限
syextract.open true 打开GUI权限
syextract.claim true 领取红包权限
syextract.broadcast true 广播红包权限
syextract.ban op 封禁玩家权限
syextract.unban op 解封玩家权限
syextract.reload op 重载配置权限
syextract.admin op 所有管理权限

配置文件

config.yml

# 语言设置
# 可选值: zh (简体中文), en (English)
language: zh

# 红包设置
red-envelope:
  # 红包默认可领取时间(小时)
  default-expire-hours: 24
  # 最小红包金额
  min-amount: 1.0
  # 最小红包数量
  min-count: 1
  # 最大红包数量
  max-count: 100

# 手续费设置(创建红包时收取)
fee:
  enabled: true
  percentage: 0.05
  min-fee: 1.0

# 税收设置(领取红包时收取)
tax:
  # 免税界限:红包总额小于此值则免税
  threshold: 10000
  # 税率:红包总额大于等于免税界限时按此比例收税
  percentage: 0.02

# 经济设置
economy:
  # 货币名称(当Vault未提供时使用)
  currency-name: "金币"

# 提醒设置
reminder:
  # 红包创建后多少秒发送未领取提醒(默认60秒)
  delay-seconds: 60

# GUI设置
gui:
  item-material: "SUNFLOWER"

# 广播消息设置
broadcast:
  envelope-completed: "&6&l🎉 红包通知 &r&7标题为 &e{name} &7的红包被领完了..."

语言文件

插件支持多语言,语言文件位于 plugins/SyExtract/lang/ 目录:

  • zh.yml - 简体中文(默认)
  • en.yml - English

你可以在这些文件中自定义所有消息。切换语言请修改 config.yml 中的 language 选项。

数据存储

插件在 plugins/SyExtract/ 目录下生成以下数据文件:

  • envelopes.yml - 红包数据(包含金额分配和领取记录)
  • bans.yml - 封禁数据
  • lang/ - 语言文件(自动生成)

使用示例

  1. 通过命令创建红包

    /sye create 新年红包 1000 10
    

    创建一个名为"新年红包"的红包,总金额1000,分为10份。创建成功后会显示红包ID。

  2. 通过GUI创建红包

    /sye open
    

    打开GUI后,点击下方的"创建红包"按钮(下界之星图标),然后在聊天框依次输入名称、金额、个数。

  3. 打开GUI领取红包

    /sye open
    

    即使当前没有可领取的红包也可以打开GUI。

  4. 广播红包

    /sye broadcast 1
    

    将ID为"1"的红包广播给所有在线玩家,玩家可以点击聊天中的"[立即领取]"按钮领取。

  5. 领取指定红包

    /sye claim 1
    

    直接领取ID为"1"的红包。

  6. 封禁玩家

    /sye ban 玩家名 7d
    

    封禁玩家7天,期间无法发放和领取红包。

注意事项

  1. 创建红包会扣除红包金额 + 手续费
  2. 红包采用"切线法"随机分配算法,每个人获得金额的概率完全相同,不存在先领多后领少的问题
  3. 过期未领取的红包金额会自动退还给发放者
  4. 每个玩家只能领取同一个红包一次
  5. 每个红包拥有唯一的数字ID,方便分享和领取
  6. 红包总额达到免税界限(默认10000)时,领取金额会被收取税费
  7. 服务器重启后红包数据完整保留,包括各份金额和领取记录
  8. 红包创建1分钟后若未领完,系统会自动提醒未领取的在线玩家

更新日志

v1.5.0

  • 修复红包金额分配算法:改用"切线法"确保每个人获得金额的概率完全相同,不再出现第一个领取者金额最大的问题
  • 修复服务器重启后红包金额重新生成导致分配错乱的bug(现在会保存和加载金额列表)
  • GUI新增"创建红包"按钮,点击后在聊天框依次输入名称、金额、个数即可创建
  • 创建红包后在屏幕上方显示BossBar进度条,实时显示剩余个数
  • 有人领取红包时自动通知发放者(含领取者名称、红包名称、金额、货币名称)
  • 新增税收系统:可在config.yml中设置免税界限(默认10000)和税率(默认2%)
  • 红包创建1分钟后若未领完,自动给未领取的在线玩家发送可点击的提醒消息
  • 广播消息和提醒消息中的领取按钮现在可以真正点击领取
  • 修复GUI多玩家同时打开时槽位映射冲突的bug
  • 修复领取最后一个红包时发送者名称显示为"Unknown"的bug
  • 新增定期清理过期红包的自动任务
  • 货币名称现在从Vault自动获取,支持在config.yml中配置备用名称

v1.4.0

  • 新增多语言支持(简体中文/English)
  • 语言文件存放在 lang/ 目录
  • 所有消息均可通过语言文件自定义
  • config.yml新增 language 选项

v1.3.0

  • 新增红包领完通知
  • 显示手气王(获得最高金额的玩家)
  • 新增 broadcast.envelope-completed 消息配置

v1.2.0

  • 修复广播消息找不到的问题(success.broadcast)
  • 修复广播消息中领取按钮不可点击的问题
  • 红包ID从随机6字符改为从1开始的顺序数字ID

v1.1.0

  • 为每个红包添加唯一ID
  • 过期未领取的红包自动退款
  • 新增 /sye broadcast 命令广播红包
  • 新增 /sye claim 命令按ID领取
  • 即使没有红包也可以打开GUI
  • 更新至Java 17兼容

v1.0.0

  • 初始版本

作者

Смотри также

Похожие подборки плагины — по версиям Майнкрафта, загрузчикам и жанрам.

Сервера Майнкрафт

Играть интереснее на сервере — выбирай в рейтинге серверов Майнкрафт и заходи прямо сейчас.

SkyBars
SkyBars Java + BE
531 онлайн
1.8 — 26.2 версия
🎮 ВЫЖИВАНИЕ ⚔️ АНАРХИЯ 🚗 ГТА РП 🎤 ГОЛОСОВОЙ ЧАТ 🎁 БЕСПЛАТНЫЙ ДОНАТ 🌟 СМП 💻 ПК+ТЕЛЕФОН
SparkTime
SparkTime Bedrock
78 онлайн
1.0 — 26.20 версия
SparkTime | Анархия на телефон
PazikCraft
9 онлайн
1.17 — 26.1.2 версия
Ванильное выживание со свадьбами, прокачкой боевых навыков и голосовым чатом
MigosMc
MigosMc Java + BE
776 онлайн
1.8 — 26.2 версия
🌿 MigosMc.net | Гриферский сервер с войс-чатом | Награды за онлайн ⭐ ВЫЖИВАНИЕ⭐ ОДИНБЛОК⭐ МИНИ-ИГРЫ
MineLauncher
Лаунчер Майнкрафт без лицензии — все версии
Бесплатный лаунчер для ПК и Андроид — все версии 26.2, 1.21.11, 26.1.1, 26.1. Fabric, NeoForge, Forge, шейдеры, моды и скины в один клик.
Без лицензии Fabric, NeoForge, Forge Моды, шейдеры, скины Все версии Майнкрафта ПК и Андроид Для слабых ПК Сервера в лаунчере
Скачать бесплатно
Windows и Андроид · Бесплатно · Без лицензии
Наш чат