GL-EcoAudit
审计、追踪并浏览您 Paper 1.21.4 服务器上的每一笔经济交易。
GL-EcoAudit 自动记录玩家之间所有的 /pay 交易,并提供直观的内置图形用户界面(GUI)菜单系统来浏览已发送和已接收的支付历史记录。该插件注重性能与灵活性,支持多种数据库后端、可配置的存储限制、自动清理以及完整的 Vault 集成。
链接
- GitHub:
- Discord:
- 问题与建议: 请使用我们的 Discord 服务器或 GitHub Issues。
功能
自动交易记录
每当玩家执行 /pay 时,插件都会捕获发送者、接收者、金额和精确的时间戳,并将其存储在数据库中。支持在线和离线玩家。
游戏内 GUI 菜单
玩家可以输入 /transactions 打开图形化菜单查看:
- 显示当前余额的玩家头像
- 已发送资金 按钮 → 分页列表显示所有已发送的交易(接收者头像、金额、日期)
- 已接收资金 按钮 → 分页列表显示所有已接收的交易(发送者头像、金额、日期)
- 导航按钮:下一页、上一页、返回和关闭
多数据库支持
选择适合您基础设施的存储后端:
| 数据库 |
类型 |
| SQLite |
嵌入式(默认) |
| H2 |
嵌入式(MySQL 兼容模式) |
| MySQL |
远程 |
| PostgreSQL |
远程 |
| MongoDB |
远程(NoSQL) |
可配置的交易限制
通过以下方式控制资源占用:
- MAX_PER_PLAYER – 每个玩家最大存储的交易数量(发送和接收分别统计)
- LIMIT_BEHAVIOR – 达到限制时的处理方式:
DELETE_OLDEST – 自动删除最旧的记录
STOP_RECORDING – 静默丢弃新交易
自动清理
在 config.yml 中设置 PURGE_AFTER_DAYS 以启用旧记录的自动清理。后台任务每小时运行一次,删除超过指定阈值的记录。
Vault 集成
与任何兼容 Vault 的经济插件(如 EssentialsX、CMI 等)无缝协作。使用 Vault API 获取玩家余额并格式化货币金额。
命令
| 命令 |
别名 |
描述 |
权限 |
/transactions |
/trans, /tx |
打开交易历史 GUI |
golden.ecoaudit.transactions |
/ecoaudit reload |
/ea reload |
重新加载所有配置文件(配置、语言、数据库、菜单) |
golden.ecoaudit.admin |
/ecoaudit purge [days] |
/ea purge [days] |
清除早于指定天数的交易记录(默认:90) |
golden.ecoaudit.admin |
权限
| 权限 |
描述 |
默认值 |
golden.ecoaudit.transactions |
允许玩家使用 /transactions 并查看自己的交易历史 |
OP |
golden.ecoaudit.admin |
允许玩家使用带有 reload 和 purge 子命令的 /ecoaudit |
OP |
使用方法
对于玩家
- 在聊天栏中输入
/transactions(或 /trans 或 /tx)。
- 菜单将打开,显示您的头像、余额以及两个按钮:已发送资金 和 已接收资金。
- 点击按钮以浏览相应的交易列表。
- 使用箭头按钮在不同页面间导航。
- 点击 返回 按钮回到主菜单,或点击 关闭 退出。
对于管理员
- 编辑任何配置文件后,使用
/ecoaudit reload 应用更改而无需重启服务器。
- 使用
/ecoaudit purge 30 手动删除所有早于 30 天的记录。
- 在
config.yml 中使用 PURGE_AFTER_DAYS 配置自动清理。
配置
config.yml – 主配置
SERVER_NAME: "Survival" # 服务器标识符,存储在每条交易记录中
TRANSACTIONS:
MAX_ENTRIES_PER_PAGE: 45 # 每个菜单页面显示的交易数量
MAX_PER_PLAYER: 100 # 每个玩家最大存储的交易数量(发送 + 接收)
LIMIT_BEHAVIOR: DELETE_OLDEST # DELETE_OLDEST 或 STOP_RECORDING
PURGE_AFTER_DAYS: 0 # N 天后自动清理(0 = 禁用)
FORMATTING:
DATE_FORMAT: "dd/MM/yyyy hh:mm:ss a" # 日期/时间格式 (SimpleDateFormat)
ECONOMY_FORMAT: "#,##0.00" # 经济金额格式 (DecimalFormat)
database.yml – 数据库配置
TYPE: "SQLITE" # SQLITE | H2 | MYSQL | POSTGRESQL | MONGO
INIT_TIMEOUT_SECONDS: 10
SETTINGS:
SQLITE:
FILE_NAME: "GL-EcoAudit"
H2:
FILE_NAME: "GL-EcoAudit"
MONGO:
AUTH_TYPE: "URI"
URI: ""
IP_ADDRESS: ""
PORT: 27017
DATABASE: "GL-EcoAudit"
AUTH:
USERNAME: ""
PASSWORD: ""
MYSQL:
IP_ADDRESS: ""
PORT: 3306
DATABASE: "GL-EcoAudit"
AUTH:
USERNAME: ""
PASSWORD: ""
POSTGRESQL:
IP_ADDRESS: ""
PORT: 5432
DATABASE: "GL-EcoAudit"
AUTH:
USERNAME: ""
PASSWORD: ""
language.yml – 消息
所有面向用户的消息均完全可自定义,支持十六进制颜色代码(&#rrggbb)。您可以编辑插件发送给玩家的每个命令响应、错误消息和通知。
menus/ – 菜单布局(每个菜单一个文件)
每个菜单在 menus/ 文件夹中都有自己独立的 YAML 文件:
| 文件 |
描述 |
transactions-menu.yml |
主菜单布局(玩家头像、发送/接收按钮、边框) |
transactions-sent.yml |
已发送交易的分页列表(条目名称、lore、导航按钮) |
transactions-received.yml |
已接收交易的分页列表(条目名称、lore、导航按钮) |
对于每个菜单,您可以自定义以下内容:
- TITLE – 物品栏标题
- Slot positions – 每个按钮出现的位置
- Material – 每个按钮的物品类型
- Name and Lore – 显示名称和描述(包含占位符
{player}、{balance}、{target}、{amount}、{date})
- Glow effect – 附魔光效的开启/关闭
安装方法
- 下载插件
- 将 JAR 文件放入服务器的
plugins/ 文件夹中。
- 确保已安装 Vault 以及一个经济类插件(如 EssentialsX、CMI 等)。
- 重启服务器或执行
/reload confirm 命令。
- 插件将自动生成
config.yml、database.yml、language.yml 以及 menus/ 文件夹。
- 根据您的服务器需求编辑配置文件,然后运行
/ecoaudit reload 以应用更改。
支持
如果您遇到 Bug、有功能建议或需要配置帮助,请加入我们的 Discord 服务器:
由 GL-Studio 开发。
GL-EcoAudit
Audit, track, and browse every economy transaction on your Paper 1.21.4 server.
GL-EcoAudit automatically records all /pay transactions between players and provides an intuitive in-game GUI menu system to browse sent and received payment history. Designed for performance and flexibility, it supports multiple database backends, configurable storage limits, automatic purging, and full Vault integration.
Links
- GitHub:
- Discord:
- Issues & Suggestions: Use our Discord server or GitHub Issues.
Features
Automatic Transaction Recording
Every time a player executes /pay, the plugin captures the sender, recipient, amount, and exact timestamp, and stores it in the database. Works with online and offline players.
In-Game GUI Menu
Players can open a graphical menu with /transactions to view:
- Their own head with current balance
- A Money Sent button → paginated list of all sent transactions (recipient head, amount, date)
- A Money Received button → paginated list of all received transactions (sender head, amount, date)
- Navigation buttons: next page, previous page, back, and close
Multi-Database Support
Choose the storage backend that fits your infrastructure:
| Database |
Type |
| SQLite |
Embedded (default) |
| H2 |
Embedded (MySQL-compatible mode) |
| MySQL |
Remote |
| PostgreSQL |
Remote |
| MongoDB |
Remote (NoSQL) |
Configurable Transaction Limits
Control resource usage with:
- MAX_PER_PLAYER – Max stored transactions per player (sent and received tracked separately)
- LIMIT_BEHAVIOR – What happens when the limit is reached:
DELETE_OLDEST – Automatically removes the oldest record
STOP_RECORDING – Silently drops new transactions
Auto-Purge
Enable automatic cleanup of old records by setting PURGE_AFTER_DAYS in config.yml. A background task runs every hour and deletes records older than the specified threshold.
Vault Integration
Works seamlessly with any Vault-compatible economy plugin (EssentialsX, CMI, etc.). Uses the Vault API to retrieve player balances and format currency amounts.
Commands
| Command |
Aliases |
Description |
Permission |
/transactions |
/trans, /tx |
Opens the transaction history GUI |
golden.ecoaudit.transactions |
/ecoaudit reload |
/ea reload |
Reloads all configuration files (config, language, database, menus) |
golden.ecoaudit.admin |
/ecoaudit purge [days] |
/ea purge [days] |
Purges transaction records older than the specified number of days (default: 90) |
golden.ecoaudit.admin |
Permissions
| Permission |
Description |
Default |
golden.ecoaudit.transactions |
Allows the player to use /transactions and view their own transaction history |
OP |
golden.ecoaudit.admin |
Allows the player to use /ecoaudit with reload and purge subcommands |
OP |
How to Use
For Players
- Type
/transactions (or /trans or /tx) in chat.
- The menu opens showing your head, your balance, and two buttons: Money Sent and Money Received.
- Click a button to browse the corresponding transaction list.
- Use the arrow buttons to navigate between pages.
- Click the Back button to return to the main menu or Close to exit.
For Administrators
- Use
/ecoaudit reload after editing any configuration file to apply changes without restarting the server.
- Use
/ecoaudit purge 30 to manually delete all records older than 30 days.
- Configure auto-purge in
config.yml using PURGE_AFTER_DAYS.
Configuration
config.yml – Main Configuration
SERVER_NAME: "Survival" # Server identifier stored in every transaction record
TRANSACTIONS:
MAX_ENTRIES_PER_PAGE: 45 # Number of transactions shown per menu page
MAX_PER_PLAYER: 100 # Maximum stored transactions per player (sent + received)
LIMIT_BEHAVIOR: DELETE_OLDEST # DELETE_OLDEST or STOP_RECORDING
PURGE_AFTER_DAYS: 0 # Auto-purge after N days (0 = disabled)
FORMATTING:
DATE_FORMAT: "dd/MM/yyyy hh:mm:ss a" # Date/time format (SimpleDateFormat)
ECONOMY_FORMAT: "#,##0.00" # Economy amount format (DecimalFormat)
database.yml – Database Configuration
TYPE: "SQLITE" # SQLITE | H2 | MYSQL | POSTGRESQL | MONGO
INIT_TIMEOUT_SECONDS: 10
SETTINGS:
SQLITE:
FILE_NAME: "GL-EcoAudit"
H2:
FILE_NAME: "GL-EcoAudit"
MONGO:
AUTH_TYPE: "URI"
URI: ""
IP_ADDRESS: ""
PORT: 27017
DATABASE: "GL-EcoAudit"
AUTH:
USERNAME: ""
PASSWORD: ""
MYSQL:
IP_ADDRESS: ""
PORT: 3306
DATABASE: "GL-EcoAudit"
AUTH:
USERNAME: ""
PASSWORD: ""
POSTGRESQL:
IP_ADDRESS: ""
PORT: 5432
DATABASE: "GL-EcoAudit"
AUTH:
USERNAME: ""
PASSWORD: ""
language.yml – Messages
All user-facing messages are fully customizable with hex color code support (&#rrggbb). You can edit every command response, error message, and notification the plugin sends to players.
menus/ – Menu Layouts (one file per menu)
Each menu has its own YAML file inside the menus/ folder:
| File |
Description |
transactions-menu.yml |
Main menu layout (player head, sent/received buttons, border) |
transactions-sent.yml |
Sent transactions paginated list (entry name, lore, nav buttons) |
transactions-received.yml |
Received transactions paginated list (entry name, lore, nav buttons) |
For each menu you can customize:
- TITLE – Inventory title
- Slot positions – Where each button appears
- Material – Item type for each button
- Name and Lore – Display name and description with placeholders (
{player}, {balance}, {target}, {amount}, {date})
- Glow effect – Enchantment glint on/off
Installation
- Download the plugin
- Place the JAR in your server
plugins/ folder.
- Ensure Vault is installed along with an economy plugin (EssentialsX, CMI, etc.).
- Restart your server or run
/reload confirm.
- The plugin will generate
config.yml, database.yml, language.yml, and the menus/ folder automatically.
- Edit the configuration files to suit your server and run
/ecoaudit reload to apply changes.
Support
If you encounter bugs, have feature suggestions, or need help with configuration, join our Discord server:
Developed by GL-Studio.
评论 0
登录后参与评分
还没有评论,来抢沙发吧