2.0.0-SNAPSHOT
OfflineCommands
Changelog
Refactor CommandStorage handling and formatting MORE INFO
- Use a List to store and manipulate commands
- Add option to remove all commands from user (*)
- Clean up code
Refactor PlayerConnectionListener for improved user management MORE INFO
- Replace the plugin variable with offlineCommands for consistency and clarity.
- Update event priority to EventPriority.LOWEST for more controlled execution.
- Add detailed comments to the onJoin method, explaining its purpose and logic.
- Add detailed comments to the onJoin method, explaining its purpose and logic.
- Implement conditional checks for user storage existence and command execution.
- Utilize the SETTINGS_PATH constant to access configuration settings.
- Update config.yml to show less users per page (5 -> 2)
enhancement: Update OfflineCommands plugin functionality MORE INFO
- Register additional classes for configuration serialization using YamlConfiguration
- Add variable to store user-specific data in a UserConfigData object
- Implement onReload() method for config and user data reload using reloadConfig() and loadUserData()
- Add onDisable() method for cleanup and unregistration using unregisterAll() main
Refactor OfflineCommandExecutor.java MORE INFO
- Use separate classes (InfoCommands and ModifyCommands) to handle different types of commands
- Add reload command to reload the plugin
- Rename methods and variables for clarity and consistency
- Change message sending logic to use configurations and variables
Add user data and storage classes MORE INFO
- Add user_data.yml file to store user information
- Add UserStorage.class to handle user data
- Add UserStorage.class to handle user data
- Add StorageUtils.class to handle user data and storage operations
- Add SoundStorage.class for handling sound for commands
- Add CommandStorage.class for handling command storage
- Modify config.yml and plugin.yml to update the plugin configuration and metadata
refactor: improve OfflineCommandUtils methods MORE INFO
- docs: adding javadoc comments to explain the functionality and usage of each method
- refactor: rename method color to applyChatColors
- style: format and indent code according to conventions
- feat: add runCommandAsPlayer method to OfflineCommandsUtils
- feat: add getDataFromUsername method to OfflineCommandsUtils
- feat: add getDataFromUUID method to OfflineCommandsUtils
About the 2.0.0-SNAPSHOT
Hello there! This project has been out of my sight for a while, and I decided to spice it up a bit! If you face any issues, please notify me. This project utilizes many new methods and features that I am still getting the hang of, and they are awesome!
What's changed?
Commands, and command handling!
- Enhanced performance: We have optimized the plugin code to make it run faster and smoother, saving you memory and CPU resources.
- Better feedback: We have improved the feedback messages to give you more information and guidance on how to use the plugin features.
- Bug fixes: We have fixed some issues that caused the plugin to crash or behave unexpectedly when dealing with invalid UUIDs or user storage objects.
- More flexibility: We have added some new parameters to the plugin commands that allow you to customize your experience. You can now use the
page
parameter to paginate the list of stored commands, and thefeedback
parameter to control whether you want to receive feedback messages or not. - Improved reliability: We have improved the
reload
command to handle errors gracefully and return a boolean value indicating the success of the operation. - Improved usability: We have improved the
tabComplete
method to provide more accurate and relevant suggestions for command arguments. - Improved help: We have improved the
help
command to return a formatted help message as a string that explains how to use the plugin commands.
Configurations and data storage
- User data serialization Users are now stored in user_data.yml and includes Objects that are serialized into a yaml format.
- Command list User data contains a list of commands, their username, and each command contains a permission that if executed, requires that player to have that permission, a message that will send to the player on execution, if successful.
- Sound effect A sound that is played whenever the command is executed.
- Executor and command value Only required inputs are executor, identifier, and command value. Here is an example of a user being stored:
users:
- ==: io.github.jochyoua.offlinecommands.storage.UserStorage
uuid: 49b23ff7-9202-47c6-97aa-e631bf4284d4
commands:
- identifier: 3e18335a
soundStorage:
==: io.github.jochyoua.offlinecommands.storage.SoundStorage
volume: 1.0
sound: BLOCK_ANVIL_BREAK
pitch: 1.0
commandValue: test
requiredPermission: offlinecommand.requires-this-permission
executor: CONSOLE
message: You just ran the command &c/test!
username: Jochyoua