Triton icon indicating copy to clipboard operation
Triton copied to clipboard

Switch to MiniMessage on messages.yml

Open diogotcorreia opened this issue 2 years ago • 5 comments

Instead of legacy & color codes, use MiniMessage on Triton's message.yml. This will be a breaking change.

diogotcorreia avatar Aug 31 '22 09:08 diogotcorreia

What about supporting both legacy color codes & MiniMessage? I personally hate MiniMessage. Few reasons why:

  1. People have to write a lot more to apply colors. -> &2Success Text vs. <dark_green>Success Text</dark_green> equals same result, but MiniMessage triples the amount of written characters.
  2. Sometimes it does not respect pair tags especially on multi-line messages. And a lot more..

ElFrod0 avatar Sep 01 '22 17:09 ElFrod0

Yep, same! Couldn't agree more, i just use minimessage for rainbow color rgb things hhh

PalmTamino avatar Sep 01 '22 18:09 PalmTamino

@ElFrod0 @PalmTamino Thanks for your feedback! I totally agree with you and will keep this in mind while implementing this

diogotcorreia avatar Sep 01 '22 19:09 diogotcorreia

I personally disagree and support the idea of just Minimessage. Enabling &c or &a adds incredible ambiguity to a config file, where does it end? What do these actually mean? Closing and Opening the colour, the boldness, italics. Telling where it's to be reset. Where a new line will be, all in a standard format is far superior to the & rubbish which is harder to digest and although shorter, perpetuating rubbish formatting. Using dark-green is an incredibly unfair example. Red, Grey, Black are much shorter. To give more context. "Hello" is valid formatting as compared to "&cHello" which shouldn't be valid because not only is it confusing when it becomes &c&l but oh wait &l&c doesn't work?? MiniMessage was designed to eliminate that. Legacy characters should stay dead. What happens if you want to use non italic text in lore? You'd have to write &r and risk running the trouble every time you change decoration for the characters to become italic again. Meanwhile <!italic> solves the problem for every single piece of text regardless of whether you make it bold, unbold. E.t.c

VQ9 avatar Sep 03 '22 13:09 VQ9

Configuration files should be as explicit as possible and legacy & color codes are confusing and error-prone.

I wholeheartedly agree with @VQ9.

It might be quicker to type out the config using & codes, but if anyone else (or even your future self!) ever needs to read and understand your messages.yml, the MiniMessage format is objectively better -- not to mention the confusing behavior that @VQ9 described when mixing and matching styles. In my opinion, using & syntax in configuration files is an extremely poor design choice and Triton should not perpetuate it.

Take advantage of the fact that you're releasing a new major version and introduce positive breaking changes.

If you really want to, see if there's a way to "translate" existing files from the legacy syntax to MiniMessage.

RafDevX avatar Sep 03 '22 19:09 RafDevX