DevLeoko / AdvancedBan

AdvancedBan is a Spigot plugin to manage punishments on single servers and server networks
GNU General Public License v3.0
158 stars 130 forks source link

Tab-Completion and Layout Configuration Options #580

Closed Hopefuls closed 2 years ago

Hopefuls commented 2 years ago

This Pull-Request includes new configuration settings to disable the use of Layouts, aswell as disabling Tab-completion. Disabling Tab-completion was previously only doable by using a plugin that fully disables tab completion.

The configuration file "config.yml" has a new section called "Use Tab Completion". This setting allows administrators to entirely disable Tab completion from AdvancedBan. This includes tab-completing users, Options and Layouts. To allow legacy configuration files, this setting is set to true by default.

The configuration file "Layouts.yml" has 2 new options called "Use Message Layouts" and "Use Time Layouts". Disabling either of them will remove Layouts from both Tab-completion, aswell as the use of it entirely. Trying to use it will respond with a message defined within the "Messages.yml" under the sections "TimeLayoutsDisabled" and "MessageLayoutsDisabled". These sections will cause issues if not present, but would not be used if Layouts are enabled by default (aka using previous configuration files). Administrators can append said sections accordingly.

As already mentioned, this should mostly not cause issues with legacy versions of configuration files, but may cause issues if "MessageLayoutsDisabled" or "TimeLayoutsDisabled" are not present. But again, this should not cause any issues through default use and can be appended by Administrators if needed.

Cheers.

DevLeoko commented 2 years ago

Thanks for contributing 👍