COWMODSКаталог модов

CoinsAndPoint

一个有金币(coins)和点券(point)两种货币的双货币经济API A dual-currency economy API featuring two types of currencies: coins and points

Автор: howze1191обновлён 31 июл. 2026 г.
Экономика

Описание

CoinsAndPoint是一个_双货币_的经济API

一、插件简介

Coins And Point 是适配 Paper 1.21.11 开发的轻量化、高稳定双货币经济插件,内置金币(coins)+点券(point)两套独立货币体系,无实体物品、纯数值存储,完美适配生存、RPG、公益服、小游戏各类服务器。 插件采用单文件全局存储,无需拆分玩家文件,维护简单;自带管理员操作二次确认机制,杜绝误操作;支持全自动定时保存、关服强制保存,数据零丢失风险;全部文本可自定义配色,兼容服务器彩色格式符号,同时提供全局占位符,可对接计分板、GUI界面等场景。

二、主要功能

  • 双货币独立体系:金币(long)、点券(int),双货币禁止负数,数值安全严谨,转账、扣款自动校验余额
  • 安全管理机制:OP增减货币需30秒二次确认,超时、输入其他内容自动取消,防误删误加数据
  • 全自动数据存储:服务启动自动加载、关闭强制全量保存、玩家在线状态5秒定时自动保存,杜绝数据丢失
  • 全配置化文本:所有提示语句统一在 config.yml 配置,支持彩色符号,可自由修改适配服务器风格
  • 玩家自由转账:支持金币、点券双向玩家互转,余额不足自动拦截并提示
  • 通用占位符支持:内置双货币全局占位符,适配计分板、玩家信息、GUI等场景
  • 轻量化无冗余:无多余依赖、无实体货币、无卡顿线程,低资源占用,适配各类配置服务器

- 预留拓展接口:开放UUID货币读写接口,可后续对接充值后台、商城系统、任务奖励等拓展功能

三、指令合集

玩家可用类

  • 指令 功能
  • /money 查看自身金币、点券数量
  • /coins 查看自身金币数量
  • /point 查看自身点券数量
  • /pay coins [玩家] [数量] 给特定玩家支付金币 金币不足时自动取消
  • /pay point [玩家] [数量] 给特定玩家支付点券 点券不足时自动取消

管理操作类

  • 指令 功能
  • /coins add/take [玩家] [数量] 添加/扣除特定玩家的金币
  • /point add/take [玩家] [数量] 添加/扣除特定玩家的点券
  • (注:管理指令需要二次执行来确认)

CoinsAndPoint is an economic API with dual-currency

I. Plugin Overview

Coins And Point is a lightweight and highly stable dual-currency economy plugin developed for Paper 1.21.11. It features two independent currency systems: coins and points, with no physical items and pure numerical storage. It is fully compatible with survival, RPG, public welfare and minigame servers of all types. The plugin uses single-file global storage without separate player files for easy maintenance. It comes with a secondary confirmation mechanism for administrator operations to prevent misoperations. It supports automatic scheduled saving and forced saving upon server shutdown to eliminate risks of data loss. All text supports customizable color schemes and server color format codes, along with global placeholders compatible with scoreboards, GUIs and other scenarios.

II. Core Functions

  • Independent dual-currency system: Coins (long type) and Points (int type). Negative balances are prohibited for both currencies with strict value validation; balance checks run automatically during transfers and deductions.
  • Secure management mechanism: OPs must confirm currency adjustments within 30 seconds. The operation auto-cancels upon timeout or irrelevant input to avoid incorrect data additions or deletions.
  • Fully automatic data storage: Auto-loads data on server startup, performs full forced saves on shutdown, and runs automatic 5-second interval saves while players are online to prevent data loss.
  • Fully configurable text: All message prompts are centralized in config.yml with color code support, fully editable to match server styles.
  • Player peer-to-peer transfers: Two-way transfers of coins and points between players, with automatic blocking and prompts for insufficient balances.
  • Universal placeholder support: Built-in global dual-currency placeholders compatible with scoreboards, player info panels, GUIs and more.
  • Lightweight and streamlined: No redundant dependencies, no physical currency items, no laggy threads, low resource consumption, compatible with servers of all hardware configurations.

- Reserved extension interfaces: Exposed UUID-based currency read/write interfaces for future integration with payment backends, mall systems, quest rewards and other extended features.

III. Full Command List

Player Commands

  • Command Function
  • /money Check personal coin and point balances
  • /coins Check personal coin balance
  • /point Check personal point balance
  • /pay coins [Player] [Amount] Send coins to a target player; auto-cancels if coins are insufficient
  • /pay point [Player] [Amount] Send points to a target player; auto-cancels if points are insufficient

Administrator Commands

  • Command Function
  • /coins add/take [Player] [Amount] Add or deduct coins for a target player
  • /point add/take [Player] [Amount] Add or deduct points for a target player
  • (Note: Administrator commands require secondary execution for confirmation)

Последние версии

Все версии →
release

0.1.6

0.1.6
31 июл. 2026 г.40Minecraft: 1.21.11paper
Скачать
Что нового
### 这是正式版本,修复了所有已知Bug! 本次更新内容: > 本次新增金币收支列表系统: > /financelist > 在聊天栏显示最近 10 条金币收支记录。 > 按时间从新到旧排列。 > /financelist all > 展示全部金币收支记录。 > 每页显示 10 条。 > 聊天栏底部提供可点击的“上一页”和“下一页”。 > 也支持内部页码格式 /financelist all <页码>。
release

0.1.5

0.1.5
30 июл. 2026 г.17Minecraft: 1.21.11paper
Скачать
Что нового
### 这是正式版本,修复了所有已知Bug! 本次更新内容: > 红包功能: > 仅使用金币,红包不收取税费。 > /redenvelope <金额> <份数> 发放全服拼手气红包。 > /redenvelope <金额> 1 <玩家> 发放指定在线玩家红包。 > 发放后向全服发送可点击的红包广播。 > 点击聊天文字进入 3 行抢红包 GUI。 > GUI 正中间为红色羊毛,点击即可领取。 > 发放者不能领取自己的红包。 > 同一个红包每名玩家只能领取一次。 > 指定红包只有被指定的玩家可以领取。 > 每名玩家默认每 5 分钟可以发放一次红包。 > 红包默认 15 分钟过期。 > 未领取的金币过期后自动返还发放者。 > 红包、领取情况和发放冷却保存在 red-envelopes.yml。 > 服务器重启后,未过期红包仍会继续存在。 > 冷却时间、过期时间、检查间隔和最大红包份数均可在配置文件修改。 > 隐藏了聊天点击使用的内部 open 参数,不会在普通指令补全中显示。 > 增加了领取者金币余额达到上限时的安全提示。
release

0.1.4

0.1.4
28 июл. 2026 г.15Minecraft: 1.21.11paper
Скачать
Что нового
### 这是正式版本,修复了所有已知Bug! 本次更新内容: > 金币和点券可以分别设置转账税率。 > 金币默认税率为 0%。 > 点券默认税率为 10%。 > 支持小数税率,例如 2.5 代表 2.5%。 > 税收从转账金额中扣除。 > 不足 1 单位的税额向下取整。 > 发送方和接收方都会收到完整的聊天栏转账记录。 > 记录包含付款人或收款人、币种、转出金额、税收、实际到账金额和当前余额。
release

0.1.3

0.1.3
27 июл. 2026 г.14Minecraft: 1.21.11paper
Скачать
Что нового
### 这是正式版本,修复了所有已知Bug! 此版本优化了插件,降低了性能消耗。优化项: > 合并金币和点券管理员命令的重复实现。 > 只有经济数据发生变化时才触发自动保存,减少无意义的磁盘读写。 > 自动保存使用安全快照,修复异步保存与主线程修改数据之间的并发风险。 > 停服时确保最新数据最后写入,避免旧的异步快照覆盖新数据。 > 清理插件关闭后的单例、定时任务和二次确认缓存。 > 增加正数、点券整数上限和余额溢出保护。 > 优化命令补全,非管理员不再获得管理操作和玩家名称补全。
release

0.1.2

0.1.2
7 июл. 2026 г.12Minecraft: 1.21.11paper
Скачать
Что нового
### 这是正式版本,修复了所有已知Bug! 我们修复了pay指令Tab索引顺序错乱的问题 如有发现任何bug,可以告知howze哦
beta

0.1.1-Beta

0.1.1-Beta
7 июл. 2026 г.9Minecraft: 1.21.11paper
Скачать
Что нового
### 这是Beta版本! 如果有遇到任何bug可以找howze反馈哦 这个版本新增了指令的Tab索引
beta

0.1.0

0.1.0-Beta
6 июл. 2026 г.12Minecraft: 1.21.11paper
Скачать
Что нового
### 这是Beta版本!如果有遇到任何bug可以找howze反馈哦