Lilend's Simple Economy (LSE)
版本:1.1 | 语言:Kotlin (JVM 21) | 平台:Paper / Purpur 1.21+ | 作者:lilend | API:LSEAPI、Vault、PlaceholderAPI
一款轻量、安全且现代化的 Minecraft Paper 1.21+ 服务器经济插件。
功能
- 玩家余额(YAML / MySQL / MariaDB / SQLite)
- 实体支票物品(通过 GUI 右键兑换)
- 支持确认 GUI 的玩家间转账
- 余额排行榜(/baltop)
- 管理员命令(add、remove、set、reload)
- 交易税系统(可配置费率及按功能设置)
- 自动保存机制(可配置间隔时间)
- Vault API 挂钩(QuickShop、ChestShop、GriefPrevention 等)
- PlaceholderAPI 扩展(%lse_balance%、%lse_balancetop_1% 等)
- 公开开发者 API(LSEAPI 对象)
- 完全自定义的消息,支持 & 颜色代码和占位符
- 各命令独立的权限控制(默认为 true 或 op)
- 可切换的功能模块(支票、转账、税收)
- 每日轮转的交易日志记录
- 安全验证(溢出保护、NaN 检查、余额上限)
- 紧凑数字格式:1K、1M、1B、1T ... Dd (Duodesillion)
- 数据库支持:YAML(默认)、MySQL、MariaDB、SQLite(v1.1)
命令
/balance 或 /bal - 显示你的余额 - lse.balance
/balance <player> - 显示其他玩家的余额 - lse.balance.others
/pay <player> <amount> - 向玩家发送金钱 - lse.pay
/check <amount> - 创建实体支票 - lse.check
/baltop 或 /top - 余额排行榜 - lse.baltop
/lse add <player> <amount> - 给玩家添加金钱 - lse.lse.add
/lse remove <player> <amt> - 从玩家移除金钱 - lse.lse.remove
/lse set <player> <amount> - 设置玩家的余额 - lse.lse.set
/lse balance [player] - 查看任意玩家的余额 - lse.lse.balance
/lse reload - 重新加载配置、消息和存储 - lse.lse.reload
权限
lse.balance - true - 查看你的余额
lse.balance.others - true - 查看他人的余额
lse.pay - true - 向玩家发送金钱
lse.check - true - 创建实体支票
lse.baltop - true - 查看余额排行榜
lse.lse - op - 管理员命令基础权限
lse.lse.add - op - 向玩家添加金钱
lse.lse.remove - op - 从玩家处移除金钱
lse.lse.set - op - 设置玩家的余额
lse.lse.balance - op - 通过 /lse 查看任意余额
lse.lse.reload - op - 重载插件配置
lse.tax.exempt - op - 免除交易税
lse.admin - op - 所有管理员权限(继承所有 lse.lse.* 权限)
数据库支持 (v1.1)
支持三种存储后端:
storage:
type: yaml # yaml, mysql, mariadb, sqlite
mysql:
host: localhost
port: 3306
database: minecraft
username: root
password: ""
pool-size: 10
sqlite:
file: data.db
- YAML(默认):balances.yml,无需额外依赖
- MySQL / MariaDB:HikariCP 连接池,高性能
- SQLite:单文件,无需配置
使用 /lse reload 切换存储类型(切换前会自动保存)。
安装
- 下载 LilendsSimpleEconomy-1.1.jar
- 将其放入服务器的 plugins/ 文件夹中
- (可选)安装 Vault.jar 以实现跨插件经济支持
- (可选)安装 PlaceholderAPI 以支持占位符扩展
- 重启或重载服务器
- 根据需要编辑 config.yml 和 messages.yml
- 运行 /balance 进行验证
更新日志
v1.1
- 新增 MySQL、MariaDB 和 SQLite 数据库支持(HikariCP 连接池)
- /lse reload 现在也会重载余额管理器和存储模块
- 支票物品描述文本现从 messages.yml 读取(完全可自定义)
- 修复重载时的存储连接泄漏问题
- 采用模块化 StorageAdapter 架构,便于后端切换
v1.0 - 初始版本
- 玩家余额系统,支持 YAML 持久化存储
- 实体检查系统(通过 GUI 右键兑换)
- 玩家间转账功能,带确认 GUI
- 余额排行榜(/baltop)
- 管理员命令(/lse add/remove/set/balance/reload)
- 集成 Vault API 并扩展 PlaceholderAPI
- 交易税系统与自动保存机制
- 紧凑数字格式(K, M, B, T ... Dd)
- 完全可自定义的消息 & 线程安全的余额管理
- 安全验证(溢出、NaN、四舍五入)
- 每日轮转的交易日志记录
Lilend's Simple Economy (LSE)
Version: 1.1 | Language: Kotlin (JVM 21) | Platform: Paper / Purpur 1.21+ | Author: lilend | API: LSEAPI, Vault, PlaceholderAPI
A lightweight, secure, modern economy plugin for Minecraft Paper 1.21+ servers.
Features
- Player balances (YAML / MySQL / MariaDB / SQLite)
- Physical check items (right-click to redeem via GUI)
- Player-to-player payments with confirmation GUI
- Balance leaderboard (/baltop)
- Admin commands (add, remove, set, reload)
- Transaction tax system (configurable rate & per-feature)
- Auto-save mechanism (configurable interval)
- Vault API hook (QuickShop, ChestShop, GriefPrevention, etc.)
- PlaceholderAPI expansion (%lse_balance%, %lse_balancetop_1%, etc.)
- Public developer API (LSEAPI object)
- Fully customizable messages with & color codes and placeholders
- Per-command permissions (default true or op)
- Toggleable features (checks, transfers, tax)
- Transaction logging with daily rotation
- Security validation (overflow protection, NaN checks, balance caps)
- Compact number format: 1K, 1M, 1B, 1T ... Dd (Duodesillion)
- Database support: YAML (default), MySQL, MariaDB, SQLite (v1.1)
Commands
/balance or /bal - Show your balance - lse.balance
/balance <player> - Show another player's balance - lse.balance.others
/pay <player> <amount> - Send money to a player - lse.pay
/check <amount> - Create a physical check - lse.check
/baltop or /top - Balance leaderboard - lse.baltop
/lse add <player> <amount> - Add money to a player - lse.lse.add
/lse remove <player> <amt> - Remove money from a player - lse.lse.remove
/lse set <player> <amount> - Set a player's balance - lse.lse.set
/lse balance [player] - View any player's balance - lse.lse.balance
/lse reload - Reload config, messages & storage - lse.lse.reload
Permissions
lse.balance - true - Check your balance
lse.balance.others - true - Check others' balances
lse.pay - true - Send money to players
lse.check - true - Create physical checks
lse.baltop - true - View balance leaderboard
lse.lse - op - Admin commands base
lse.lse.add - op - Add money to a player
lse.lse.remove - op - Remove money from a player
lse.lse.set - op - Set a player's balance
lse.lse.balance - op - View any balance via /lse
lse.lse.reload - op - Reload plugin configuration
lse.tax.exempt - op - Exempt from transaction taxes
lse.admin - op - All admin permissions (inherits all lse.lse.*)
Database Support (v1.1)
Three storage backends are supported:
storage:
type: yaml # yaml, mysql, mariadb, sqlite
mysql:
host: localhost
port: 3306
database: minecraft
username: root
password: ""
pool-size: 10
sqlite:
file: data.db
- YAML (default): balances.yml, no extra dependencies
- MySQL / MariaDB: HikariCP connection pool, high performance
- SQLite: Single file, no setup required
Use /lse reload to switch storage types (auto-saves before switching).
Installation
- Download LilendsSimpleEconomy-1.1.jar
- Place it in your server's plugins/ folder
- (Optional) Install Vault.jar for cross-plugin economy support
- (Optional) Install PlaceholderAPI for placeholder expansion
- Restart or reload your server
- Edit config.yml and messages.yml to your liking
- Run /balance to verify
Changelog
v1.1
- MySQL, MariaDB and SQLite database support (HikariCP connection pool)
- /lse reload now also reloads balance manager and storage
- Check item lore now reads from messages.yml (fully customizable)
- Storage connection leak fixed on reload
- Modular StorageAdapter architecture for easy backend switching
v1.0 - Initial release
- Player balances with YAML persistence
- Physical check system (right-click redeem with GUI)
- Player-to-player payments with confirmation GUI
- Balance leaderboard (/baltop)
- Admin commands (/lse add/remove/set/balance/reload)
- Vault API integration & PlaceholderAPI expansion
- Transaction tax system & auto-save mechanism
- Compact number format (K, M, B, T ... Dd)
- Fully customizable messages & thread-safe balance management
- Security validation (overflow, NaN, rounding)
- Transaction logging with daily rotation
评论 0
登录后参与评分
还没有评论,来抢沙发吧