You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The locale module was written very quickly and sloppily. It needs love and to possibly to be moved out of the module system scope. More to come later...
The text was updated successfully, but these errors were encountered:
Locale has been refactored into a manager outside of the module scope; however, I'm not sure about the static access from StringHelper. I would rather not offload such a task to StringHelper, but more thinking is needed.
Essentials(X) currently uses a static method everywhere, I18n.tl, but in the future EssentialsX may change this to support placeholders and per-player locales.
Nucleus uses an instance of a MessageProvider, which is responsible for providing the messages from either a config file or resource bundle. Sending messages is done using methods on MessageProvider. To reduce repetition, it also has helper methods in MessageProviderTrait implemented on listener and command classes as needed. I'm not certain but it looks like Nucleus already supports per-player locale, or at least has the groundwork for it.
I'm kind of fond of the idea of a message provider. I'm kind of torn between adding more classes simply for locale support, and adding the messaging methods to the actual LocaleManager since I would rather is just manage locales rather than proxy messages
The locale module was written very quickly and sloppily. It needs love and to possibly to be moved out of the module system scope. More to come later...
The text was updated successfully, but these errors were encountered: