Please delete any and all previous files of this plugin before updating to this new version:
Bugs:
- Fixed
major issue of invites getting reset after every server restart
- Fixed
major issue with config file not updating which caused any features of it to not work
Features:
- Added 2 more files to the plugin's folder -
messages.yml and
whitelist.yml messages.yml is a file that stores all of the messages of the plugin (except console-only messages), and whitelist.yml stores the whitelist aswell as the Unique User ID + the number of invites they sent out
- Added a config option:
debug: false
this option turns on the debug mode for this plugin which sends extra information in the console (unless you run into an issue there is no reason to change it from its default value of 'false')
- Added 3 more commands to make the configuration of this plugin much more user-friendly:
: /wl setlimit <number> - sets the maximum invite limit to whatever number you choose
: /wl setenforced <boolean> - sets the whitelist enforcing to either true or false
: /wl setdebug <boolean> - sets the debug mode of this plugin
This means that you no longer need to edit the config directly, which also might prevent many user caused issues!
On the actual code (this will likely not be important for most users, but feel free to read!):
- Almost completely recoded the plugin, making it much more efficient and readable
- Instead of the previous map I used for the messages, I now changed it to an enum which stores all the messages (same for config options)
- Gone over all of the code and implemented features that might prevent some possible bugs in the future
- Created a class (DataManager.class) that takes care of all the plugin's files, which is built on a custom configuration class
- Separated a lot of the methods into multiple, smaller methods which allow me to much more easily change any code
- Added a few safeguards to make sure that the plugin won't be easily broken by config changes
This recode was a very long and tedious process as it caused me to run into many many bugs, but after a good ~15 hours of work I can finally say I'm quite happy with this plugin in its current state.
Please please do make sure to report any and all problems you encounter in the discussion tab!
And I would also appreciate seeing some reviews in the reviews section so I can learn and improve on the plugin!
Thank you all, have a wonderful day!