YuPay Changelog - Version 1.1.1
Dear server owners and players, thank you for using YuPay! This update (1.1.1) focuses on optimizing and enhancing configuration management, the logging system, sound compatibility, and PlaceholderAPI integration, making the plugin even smoother to use. Here are the detailed changes:
✨ New Features & Enhancements
1. Smart Configuration Update Mechanism (No more manual tweaking!)
- When an outdated configuration file is detected, the plugin automatically backs up the old file (e.g., config.yml.backup_1) and generates a brand new default configuration.
- Automatically preserves your custom settings: The plugin intelligently identifies keys present in both the old and new configurations and migrates only those values from the old config to the new one. This ensures that your crucial settings—such as payment keys, database passwords, exchange rates—are never lost, while you still get the latest default options.
- The configuration update process is fully transparent, with detailed logs printed to the console.
2. Enhanced Messaging System (Goodbye to startup error logs)
- The message manager (MessageManager) now has a built-in fallback mechanism. Even before updating configuration files, it can load default messages from the plugin's JAR, ensuring all logs and prompts display correctly.
- No more repetitive "message missing" warnings at startup; console output is much cleaner.
3. Improved Sound Utilities (More stable cross-version compatibility)
- SoundUtils now uses lazy initialization, performing version detection only after the plugin has fully loaded, avoiding issues with accessing plugin instances during class loading.
- All log output now uses the plugin's own Logger and supports customization via the message file, making it easier to unify log formatting.
- Friendlier error messages when sound playback fails, with fallback sounds ensuring functionality remains unaffected.
4. PlaceholderAPI Expansion Upgrade (More useful placeholders)
- Version synchronization: The placeholder expansion version now matches the plugin's main version (changed from 1.0 to 1.1.1), no longer hardcoded.
- New placeholders:
- %yupay_total_all% – Total server-wide donations (CNY)
- %yupay_recent_day% – Player's donations in the last 24 hours
- %yupay_recent_week% – Player's donations in the last 7 days
- %yupay_recent_month% – Player's donations in the last 30 days
- Existing placeholders (%yupay_total%, %yupay_rank%, %yupay_top{n}_name%, %yupay_top{n}_amount%) remain stable and fully functional.
5. Internal Code Optimizations
- Removed all hardcoded log texts; now unified through the message manager for better multi-language support.
- Improved command registration logic to ensure custom primary names and aliases work correctly.
- Enhanced exception handling in database queries to prevent a single failure from affecting the entire plugin.
Bug Fixes
- Fixed the issue where "message missing" warnings repeatedly appeared at startup due to outdated message files.
- Fixed the bug where the PlaceholderAPI expansion version always showed as 1.0.
- Fixed compatibility issues in SoundUtils that could cause sound constants not to be found on older server versions.
- Fixed the problem where user customizations could be accidentally overwritten during configuration updates (now smart retention is implemented).
How to Update
- Replace the old YuPay.jar in your server's plugins folder with the new version.
- Highly recommended: On the first startup with the new version, the plugin will automatically back up and update your configuration files. If you've made custom changes before, please check config.yml and messages.yml to ensure your custom values are retained, and verify that the new version numbers (config-version and messages-version) have been updated to 1.
- If you use PlaceholderAPI, the new placeholders will take effect immediately without any extra steps.
Feedback & Support
If you encounter any issues or have suggestions, feel free to join our community group: 1080918424 (QQ)