In preparation for a suggestion I will be making regarding how this server gives freedom to take care of a persistent issue that's been plaguing it for years, I decided to attempt an implementation of proper permission nodes in the TotalFreedomMod as a proof of concept.
Technical Details
It was surprisingly easy to get permission nodes for commands. The implementation I came up with is pretty rudimentary. when an instance of a command class has been created, it uses the class's name to create a permission node automatically. When said instance is registered, it sets the automatically-created permission node as the command's permission node. The check for permissions is replaced with a simple sender.hasPermission() check. All of this done in FreedomCommand, so there is usually no need to modify any existing commands to use this new permission system. As a result, anybody who wrote custom commands in a fork of the plugin won't have to worry about having to change them to be compatible with this implementation.
Benefits
- You could use third party plugins like LuckPerms to manage permissions for commands.
- This makes the TotalFreedomMod's command system much more customizable and easy to adjust. Want to give a group of players access to /fuckoff? No need to recompile the plugin, just use /lp group <group name> permission set totalfreedommod.command.fuckoff true. Want to restrict a certain part of a command to a higher rank? No problem, just use /lp group <group name> permission set totalfreedommod.command.<command name>.<portion>. Want to give a specific player access to a command? Easy, just do /lp user <username> permission set totalfreedommod.command.<command>. No need to wait months for a single permission change to a command, just run one command and you're done.