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

ВЕРСИИ (11)

release

MPromoCodes v1.8 — Voucher Operations & Automation Update

1.8
2 окт. 2026 г.122Minecraft: 1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11, 26.1, 26.1.1, 26.1.2, 26.2folia, paper, purpur
Скачать
Что нового
This update expands MPromoCodes with a complete operations toolkit for reusable templates, unique voucher batches, safe recovery, auditing and reward testing. Bulk work runs through a bounded background queue and generated vouchers start disabled by default, making the new workflow suitable for large production servers. ## Added - Added reusable voucher templates stored in `templates.yml`. - Added collision-safe bulk generation of unique voucher codes. - Added configurable voucher masks using `X` placeholders. - Added a configurable unambiguous generation alphabet without `0/O` and `1/I/L` by default. - Added a configurable per-batch limit with an additional hard safety cap. - Added batch metadata in `batches.yml`, including template, campaign, creator, creation time, mask and code list. - Added batch-wide enable, disable, archive and restore operations. - Added TXT and CSV batch export to the protected `exports` directory. - Added code search by code name, batch, template or campaign. - Added safe code archiving and restoration without deleting redemption history. - Added a persistent asynchronous JSONL audit log with size-based rotation. - Added `/codes audit [page]` for recent administrative activity. - Added reward preview with type, enabled state, chance, weight and value. - Added reward test delivery to an online player without consuming the code, changing limits or starting a cooldown. - Added safe player usage/cooldown and global-use reset tools. - Added reset support for YAML, SQLite and MySQL storage. - Added dedicated permissions for voucher operations, audit access, resets and reward testing. - Added full English and Slovak localization for all new command output and help entries. ## Changed - Generated voucher batches are disabled by default until an administrator reviews and enables them. - Bulk generation, exports and batch mutations now run on one bounded background worker. - The old GUI delete action now archives and disables codes instead of permanently removing their definition. - Archived codes are excluded from the active runtime registry and normal/expired/upcoming GUI lists. - Restored codes remain disabled until an administrator explicitly enables them. - `/codes help` now includes the new permission-aware 1.8 workflows. - `config-version` is now `1.8`. ## Improved - Improved safety for giveaways, creator campaigns, one-time purchases and externally distributed voucher lists. - Improved large-server behavior by bounding queued operations and keeping bulk disk work off the server thread. - Improved recovery from configuration mistakes through archive/restore and targeted resets. - Improved traceability without leaking complete generated voucher lists into the audit log. - Improved export safety by restricting output paths to the MPromoCodes data directory. - Improved case-insensitive collision detection and mask validation. ## Storage & Data Safety - Existing `codes.yml`, `campaigns.yml`, redemption data and databases are preserved. - `templates.yml` and `batches.yml` are created automatically when missing and are treated as live administrator data. - Stable internal code IDs continue to preserve history when public code names change. - Player resets operate on the stable internal ID and can target only cooldown or both usage and cooldown. - SQL resets execute on the existing bounded storage workers; player resets use transactions. - Audit entries store operation metadata and counts, not every secret voucher value. ## New Commands ```text /codes template list /codes template save <template> <code> /codes template delete <template> /codes batch list /codes batch generate <batch> <template> <amount> [mask] [campaign] /codes batch export <batch> <txt|csv> /codes batch enable <batch> /codes batch disable <batch> /codes batch archive <batch> /codes batch restore <batch> /codes search [query] [page] /codes search --archived [page] /codes archive <code> /codes restore <code> /codes preview <code> /codes test <code> [online-player] /codes audit [page] /codes reset player <player> <code> <usage|cooldown> /codes reset global <code> ``` Use `-` to keep the default mask while supplying a campaign, for example: ```text /codes batch generate summer-drop summer-template 250 - summer-2026 ``` ## New Permissions - `mpromocodes.admin.vouchers` - `mpromocodes.admin.audit` - `mpromocodes.admin.reset` - `mpromocodes.admin.test` All four are included as children of `mpromocodes.admin` and default to server operators. ## Migration Notes - Updating from 1.7/1.7.5 triggers the existing version-aware configuration migration. - The old `config.yml` is preserved as `config-old.yml` or a collision-safe versioned/numbered backup. - A fresh 1.8 `config.yml` is generated with the complete `operations` section. - Copy your customized values from the backup into the new template after the first start. - `codes.yml`, `campaigns.yml`, `templates.yml`, `batches.yml`, locale customizations and storage data are never replaced by this template migration.
release

MPromoCodes v1.7.5 — Quality of Life & Premium Webhooks Update

1.7.5
25 авг. 2026 г.103Minecraft: 1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11, 26.1, 26.1.1, 26.1.2, 26.2folia, paper, purpur
Скачать
Что нового
This update focuses entirely on polish, clarity and day-to-day administration. It makes commands easier to discover, player redemption history easier to inspect, the code editor less chaotic and Discord notifications look like a premium integration. ## Added - Added a completely redesigned `/codes` help menu. - Paginated for future commands. - Shows only commands the sender can use. - Includes a short description for every command. - Commands are clickable in-game and include hover descriptions. - Console output remains clean and readable. - Added `/codes help [page]`. - Added paginated personal statistics with `/codes stats [page]`. - Added `/codes stats <player> [page]` for administrators. - Supports online players. - Supports offline players known to the server cache. - Uses UUID data internally, so name changes do not break stored history. - Works from the server console when a player is specified. - Added the new `mpromocodes.admin.stats.others` permission. - Added permission-aware tab completion for help, stats, menu, reload, health and webhook commands. - Added Discord Components V2 messages with: - Clean accent-free containers. - Large emoji header sections with logo thumbnails. - Separate player, promo-code, result and server-context sections. - Clean separators. - Emoji-labelled values and compact code styling. - Discord-native absolute and relative timestamps. - Success, failure and test designs. - Added the official MPromoCodes Modrinth image as the default webhook avatar and thumbnail. - Added webhook campaign information. - Added configurable compact UUID display. - Added configurable webhook field visibility. - Added an automatic legacy-embed fallback if Discord rejects a Components V2 request. - Added all new messages to both English and Slovak localization files. - Added automatic version-aware `config.yml` migration with collision-safe backups. ## New Webhook Settings These values are included in the fresh configuration generated during an upgrade and can be adjusted under `discord-webhook`: ```yaml discord-webhook: message-style: "COMPONENTS_V2" # COMPONENTS_V2 or LEGACY_EMBED fallback-to-legacy: true avatar-url: "https://cdn.modrinth.com/data/5XgdhBMc/90edf839b06799d8801b81a1942416b3b68eeeca_96.webp" branding: show-logo: true logo-url: "https://cdn.modrinth.com/data/5XgdhBMc/90edf839b06799d8801b81a1942416b3b68eeeca_96.webp" footer: "MPromoCodes" test-color: "#5865F2" display: show-uuid: true compact-uuid: true show-server: true show-campaign: true show-remaining: true show-time: true ```
release

MPromoCodes v1.7 — Campaigns & Reward Studio Update

1.7
15 авг. 2026 г.16Minecraft: 26.1, 26.1.1, 26.1.2, 26.2folia, paper, purpur
Скачать
Что нового
# MPromoCodes v1.7 — Campaigns & Reward Studio Update This update expands MPromoCodes into a complete promotion-management system. It adds campaign scheduling and analytics, a redesigned admin menu, a flexible Reward Studio, and safe code duplication and renaming while preserving compatibility with existing configurations. ## Added - Campaigns with configurable name, description, icon, enabled state, start date and expiry date. - One optional campaign assignment per promo code. - Campaign-wide activation checks: both the campaign and the code must be active. - Campaign analytics loaded asynchronously from YAML, SQLite or MySQL: - Total successful redemptions - Unique players - Paginated per-code redemption breakdown - Reward Studio with these reward types: - Console command - Player command - Private message - Full-metadata item from the administrator's hand - Experience points - Experience levels - Sound - Title and subtitle - Action bar - Potion effect - Broadcast - Reward selection modes: `ALL`, `RANDOM_ONE`, `WEIGHTED_ONE` and `CHANCE_EACH`. - Configurable weight, chance, fixed/random amounts, sound volume/pitch, title timings and potion settings. - Safe code duplication: `summer` becomes `summer-copy`, then `summer-copy-2` when needed. - Safe code renaming with preserved history, global/player counters and cooldowns. - Stable internal code IDs for newly created codes and renamed legacy codes. - Configurable item/experience safety limits. ## Changed - Completely reorganized the admin GUI into dedicated code, condition, campaign, analytics and reward screens. - New duplicated codes are disabled by default and do not copy redemption history. - Deleting a campaign now unassigns its codes without deleting them. - Code lists now show campaign, reward count and global-limit information. - Upcoming and expired lists also respect campaign activation windows. - New codes use the structured reward format automatically. ## Compatibility & Migration - Existing `codes.yml`, redemption history and databases remain compatible. - Existing codes do not require an `internal-id`; their original name is used as the stable identity automatically. - Legacy `commands:` rewards continue to work unchanged. - Opening and editing a legacy code in Reward Studio converts only that code to structured `rewards:`. - Existing `&` colors, bold formatting and message design remain supported. - Back up the plugin data folder or database before updating, as with every production release.
release

MPromoCodes v1.6 — Production, Monitoring & Localization Update

1.6
26 июл. 2026 г.37Minecraft: 26.1, 26.1.1, 26.1.2, 26.2folia, paper, purpur
Скачать
Что нового
# MPromoCodes v1.6 — Production, Monitoring & Localization Update This is the largest MPromoCodes update so far. It combines a complete production-focused code rework with new health monitoring, optional spark integration, full localization support, safer storage operations, improved Folia compatibility, and many reliability improvements for large servers. > **Requirements:** Java 25 and Paper/Folia 26.1 ## Added ### Health Check & Monitoring - Added the new `/codes health` command. - Added the new `mpromocodes.admin.health` permission. - Added optional integration with the public spark API. - When spark is installed, the health report includes: - TPS - Average and 95th percentile MSPT - Process CPU usage - System CPU usage - Added automatic Paper/JVM fallback metrics when spark is not installed. - Added MPromoCodes-specific performance metrics: - Recent redemption attempts - Successful redemptions - Rejected redemptions and errors - Average and 95th percentile redemption latency - Average and 95th percentile storage latency - Average and 95th percentile reward latency - Measured Paper/Folia server-thread time - MPromoCodes server-thread share percentage - Added JVM heap memory usage to the health report. - Added storage reachability and ping checks. - Added SQL worker queue and HikariCP pool statistics. - Added Discord webhook in-flight request and capacity statistics. - Added loaded-code and pending-player statistics. - Added configurable warning and critical thresholds for TPS, MSPT, CPU, plugin server-thread share, and storage latency. - Health metrics are collected on demand. The monitoring system does not create a permanent polling task. ### Localization - Added complete English localization in `lang/en_US.yml`. - Added complete Slovak localization in `lang/sk_SK.yml`. - Added automatic language selection based on the player's Minecraft client locale. - Added configurable default and fallback locales for the console and unsupported client languages. - Added support for additional custom locale files in the `lang` directory. - Moved all player-facing and administrator-facing UI text to localization files, including: - Redemption messages - Validation and error messages - Admin chat prompts - Inventory titles - Item names and lore - Update notifications - Health reports - Discord webhook text - Preserved legacy `&` color and formatting codes. - Added automatic merging of newly introduced language keys without overwriting existing customized values. - Added a safe one-time migration of old `config.yml` messages into the configured default locale file. ### Promo Code & Developer Features - Added configurable per-player use limits. - Added player use counts, last-use dates, and active cooldowns to `/codes stats`. - Added `PromoCodePreRedeemEvent` for cancellable pre-redemption integrations. - Added `PromoCodeRedeemEvent` after a successful atomic storage reservation. - Added sequential reward execution with `%player%`, `%uuid%`, and `%code%` placeholders. - Added stricter validation for dates, durations, conditions, materials, advancements, and statistics. ## Changed - Reworked the complete internal redemption flow for production use. - Player data is now handled using UUID-based records instead of relying only on player names. - Storage operations now reserve redemptions atomically before rewards are executed. - Global and per-player limits are now safe during concurrent redemption attempts. - Promo code definitions are parsed once into an immutable validated runtime registry. - Invalid promo code definitions are rejected instead of becoming partially active. - Reloads now validate and replace runtime definitions safely. - Existing active definitions remain available when a reload fails. - Reward entries now run sequentially on the correct Paper/Folia scheduler. - Player operations, global console commands, callbacks, and GUI reopen operations now use Folia-aware scheduling. - The admin GUI now uses typed inventory holders instead of identifying menus by inventory titles or item display names. - Admin menus now read and write promo codes through the centralized `codes.yml` manager. - Update notifications now use the player's selected language. - Discord webhook labels, titles, reasons, and status text are now configurable through locale files. - The plugin version has been updated to `1.6`. ## Improved - Improved performance and safety for large servers. - Improved MySQL concurrency using transactions and row locking. - Improved MySQL connection management using HikariCP. - Improved protection against database outages with bounded SQL worker queues. - Improved SQLite performance and concurrency using WAL mode and a bounded asynchronous worker. - Improved YAML storage with debounced saves, temporary files, and atomic file replacement where supported. - Improved legacy player-data migration from lowercase names to UUID records. - Improved fail-closed behavior when storage is unavailable. - Improved Discord webhook delivery with request timeouts, bounded in-flight work, and retry handling for rate limits and server errors. - Improved anti-spam protection and failed-attempt handling. - Improved code organization by separating configuration, storage, services, menus, localization, monitoring, API events, and integrations. - Improved Paper API compatibility by replacing old chat, title, and item metadata handling with Adventure components. - Improved build reliability with Java/Maven version enforcement and stricter compiler warnings. - Improved OneDrive compatibility for `mvn clean` on Windows. - Preserved customized message colors and formatting during the localization rework. - Removed unused utilities, old task code, obsolete configuration classes, and other dead code. ## Fixed - Fixed race conditions that could allow global or per-player limits to be overspent. - Fixed stale in-memory storage state on larger or multi-instance setups. - Fixed unbounded memory growth during SQL outages by using bounded queues. - Fixed unsafe Bukkit API access from asynchronous threads. - Fixed several Folia scheduler and player-region compatibility issues. - Fixed invalid definitions being partially loaded after configuration errors. - Fixed reload failures replacing valid active definitions. - Fixed admin inventories depending on localized or customized inventory titles. - Fixed menu actions depending on item display names. - Fixed several mismatched advancement/statistic admin-menu slots. - Fixed hardcoded admin, GUI, update, webhook, and player messages. - Fixed Maven clean failures caused by locked/read-only OneDrive-generated directories where force cleanup is supported. ## Commands & Permissions - `/code <code>` — redeem a promo code (`mpromocodes.use`) - `/codes stats` — view personal promo code statistics - `/codes menu` — open the admin menu (`mpromocodes.admin`) - `/codes reload` — reload and validate the plugin (`mpromocodes.admin`) - `/mpromocodes reload` — reload and validate the plugin (`mpromocodes.admin`) - `/codes health` — display the health report (`mpromocodes.admin.health`) - `/codes webhook test` — send a Discord webhook test (`mpromocodes.admin.webhook`) ## Migration Notes - Back up the MPromoCodes data folder or database before updating. - Replace the old plugin JAR with `MPromoCodes-1.6.jar` and restart the server. - Existing `codes.yml` and redeemed-player data remain compatible. - Existing YAML data can still be migrated automatically to SQLite or MySQL when `storage.auto-migrate-yaml` is enabled and the target database is empty. - On the first start, existing custom messages from `config.yml` are copied into the configured default locale file. - Existing customized locale values are preserved. Only missing bundled keys are added automatically. - The old `config.yml` message section is no longer used after migration; messages should now be edited in `plugins/MPromoCodes/lang`. - Legacy `&` colors continue to work exactly as before. - spark is optional. If it is not installed, MPromoCodes automatically uses Paper/JVM fallback metrics. - Servers sharing one MySQL database must use the same `codes.yml` definitions on every instance. ## New Configuration Sections ```yaml localization: default-locale: "en_US" fallback-locale: "en_US" use-client-locale: true monitoring: enabled: true spark-integration: true sample-window-seconds: 60 thresholds: tps-warning: 18.0 tps-critical: 15.0 mspt-warning: 40.0 mspt-critical: 50.0 cpu-warning-percent: 80.0 cpu-critical-percent: 95.0 plugin-main-thread-warning-percent: 1.0 plugin-main-thread-critical-percent: 3.0 storage-p95-warning-ms: 50.0 storage-p95-critical-ms: 200.0 ``` ## Monitoring Notes - CPU, TPS, and MSPT values use the public spark API when spark is available. - The MPromoCodes server-thread percentage is measured directly by MPromoCodes and is separate from the percentage shown for a node in spark's sampling-profiler call tree. - On Folia, the metric includes measured region-thread and global-region work performed by MPromoCodes. - A low MPromoCodes percentage with high server MSPT usually means the lag is coming from another plugin, world activity, entities, chunks, or the server itself. ## Why Is the Plugin File Still Large? MPromoCodes includes the SQLite and MySQL database drivers directly inside the plugin JAR. This allows server owners to use SQL storage without installing additional libraries. The native SQLite libraries support multiple operating systems and are responsible for most of the file size. This is expected and does not increase normal runtime memory usage by the full JAR size.
release

MPromoCodes 1.5.1

1.5.1
13 мая 2026 г.221Minecraft: 1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11, 26.1, 26.1.1, 26.1.2bukkit, folia, paper, purpur, spigot
Скачать
Что нового
# MPromoCodes v1.5.1 ## Bug Fixes - Fixed Admin Menu showing `Code not found` for existing codes. - Fixed Conditions Menu that was still checking codes from `config.yml` - Fixed code key handling for mixed-case promo codes. - Fixed expired/upcoming lists not preserving real code names from `codes.yml`.
release

MPromoCodes 1.5

1.5
12 мая 2026 г.24Minecraft: 1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11, 26.1, 26.1.1, 26.1.2bukkit, folia, paper, purpur, spigot
Скачать
Что нового
# MPromoCodes v1.5 — Storage & Integration Update This update brings a major internal upgrade to MPromoCodes, adding Discord webhook integration, a new separated codes file, advanced storage options, anti-spam protection and new global settings. ## Added - Added Discord webhook integration. - Added Discord webhook test command: - `/codes webhook test` - Added webhook logs for successful code redemptions. - Added webhook logs for failed code redemption attempts. - Added configurable webhook embed colors. - Added configurable webhook username and avatar URL. - Added `codes.yml` as a separate file for promo codes. - Added automatic migration from old `config.yml` codes to `codes.yml`. - Added automatic backup of old config as `config-old.yml`. - Added new storage system with multiple storage backends: - YAML - SQLite - MySQL - Added automatic YAML-to-SQL migration for redeemed code data. - Added anti-spam protection for failed redemption attempts. - Added temporary blocking after too many failed attempts. - Added configurable failed-attempt cooldown. - Added configurable block time. - Added general plugin settings: - `debug` - `case-insensitive-codes` - `trim-code-input` - `min-code-length` - `max-code-length` - `use-permission` - Added configurable server name for webhook logs. - Added new config messages: - `anti-spam-blocked` - `anti-spam-cooldown` - `invalid-code-length` ## Changed - Promo codes are now stored in `codes.yml` instead of `config.yml`. - Admin menu now reads and writes promo codes from `codes.yml`. - Redeemed code data can now be stored in YAML, SQLite or MySQL. - The `/code` command now respects configurable input rules. - Permission required to redeem codes is now configurable. - Code length validation is now configurable. - Code matching can now be case-sensitive or case-insensitive. - Code input trimming can now be enabled or disabled. - Webhook logs now include more detailed redemption information. - Internal redeem storage has been refactored for better future compatibility. ## Improved - Improved code organization. - Improved update compatibility for existing users. - Improved config structure by separating plugin settings and promo code data. - Improved admin workflow for managing promo codes. - Improved protection against invalid code spam. - Improved support for larger servers and networks through SQL storage. - Improved debug logging for redeem attempts when debug mode is enabled. ## Fixed - Fixed promo code data being mixed with global plugin settings. - Fixed hardcoded redeem permission by moving it to config. - Fixed hardcoded code input behavior by making it configurable. - Fixed admin menu storage behavior after moving codes to `codes.yml`. - Fixed future compatibility issues with redeemed code storage. ## Migration Notes - Existing promo codes from `config.yml` will be automatically moved to `codes.yml`. - The old `config.yml` will be backed up as `config-old.yml`. - A fresh `config.yml` will be generated with the latest settings. - Existing redeemed data from `redeemed.yml` can be automatically migrated into SQLite or MySQL when `storage.auto-migrate-yaml` is enabled. - Server owners should review the new `storage` section before switching to MySQL. ## Why is the file larger now? MPromoCodes now includes built-in SQLite and MySQL support. The required database drivers are bundled directly inside the plugin `.jar`, so server owners do not need to install any extra libraries. Because of these bundled SQL drivers, especially SQLite native libraries for different operating systems, the file size is larger than previous versions. This is expected and completely normal. ## New Config Sections ```yml settings: enabled: true server-name: "survival" debug: false case-insensitive-codes: true trim-code-input: true min-code-length: 2 max-code-length: 32 use-permission: "mpromocodes.use" anti-spam: enabled: true failed-attempt-cooldown: "3s" max-failed-attempts: 5 block-time: "1m" reset-on-success: true webhook-log-blocked-attempts: true storage: type: "YAML" auto-migrate-yaml: true sqlite: file: "storage.db" mysql: host: "localhost" port: 3306 database: "mpromocodes" username: "root" password: "password" use-ssl: false table-prefix: "mpromocodes_"
release

MPromoCodes 1.4

1.4
30 апр. 2026 г.30Minecraft: 1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11, 26.1, 26.1.1, 26.1.2bukkit, folia, paper, purpur, spigot
Скачать
Что нового
- Added support for version 26.1 - Added 20+ conditions to use for redeeming codes - Added Player Usage Limit - Reworked Storage system - More optimized code - Full support for Spigot and Bukkit servers
release

MPromoCodes 1.3

1.3
27 дек. 2025 г.102Minecraft: 1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11folia, paper, purpur
Скачать
Что нового
- Added option to enable/disable code - Added Admin Menu for easier code configuring - Added option to create codes ingame menu - Added option to delete codes ingame menu - Added option to view all codes and edit them ingame menu - Added option to view all upcoming codes - Added option to view all expired codes
release

MPromoCodes 1.2

1.2
21 дек. 2025 г.27Minecraft: 1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11folia, paper, purpur
Скачать
Что нового
- Added start-date feature - Added expiry-date feature - Added update checker
release

MPromoCodes 1.1

1.1
18 дек. 2025 г.29Minecraft: 1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11folia, paper, purpur
Скачать
Что нового
- Added **Global Uses** for codes - Added **bStats**
release

MPromoCodes 1.0

1.0
15 дек. 2025 г.39Minecraft: 1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11folia, paper, purpur
Скачать
Что нового
- Redeem promo codes using **/code** - Fully configurable rewards via config - Supports console and player command execution - **Title** & **Subtitle** messages after successful redemption - Per-player code usage (one-time codes) - Permission-based code access - Folia compatible - Clean and simple configuration