Sueta

JsonMessage API

2.3.0

A single class API enabling full control over json messages to be sent in chat

·Plugin
  1. 2.3.0latestEliminating NMS Usage for 1.16+ SupportJun 1, 2021
    For the sake of ensuring compatibility across all future NMS code changes, I’ve eliminated the usage of NMS entirely and switched to internally calling the tellraw command. Since the tellraw command was only added in 1.7.2, version support for prior Minecraft versions has been dropped, but it’s a small price to pay, considering how few servers still run at such old versions.
    1 download
  2. 2.2.1Respecting Style CodesFeb 22, 2021
    In previous versions, style codes (bold, italic, underline, magic, strikethrough, reset) weren’t properly respected. This version will convert these codes into their respective JSON settings without interfering with colors. Apologies that this patch was so delayed. Admittedly, I do very little plugin development these days, and so I do rely on receiving messages from my library users if there’s a potential issue. Stay warm and healthy.
    47 downloads
  3. 2.2.0The prodigal son returnsJun 1, 2018
    Anyone who's ever worked with Json Messages in Minecraft will know that a long time ago, Mojang's good work broke Json chat message colors when the client splits the message into a new line on their screen for longer messages. It's about time I made an update to JsonMessage that removes chat color codes from the raw text, and utilizes the "color" attribute as Mojang wants. However, fear not. The methods for creating colorized Json chat messages has not changed. Input the chat messages as you would for any normal messages and JsonMessage will take care of the rest for you! No more broken colors, ever! Unfortunately 1.12 removed achievements. They're being fazed out by Mojang in favor of "Advancements". I'll add support for these again once Mojang figures out what it is they're doing. I've also added a static utility command for sending raw json as a message to a player. Someone did a benchmark with JsonMessage against Fanciful and reported that JsonMessage was more than 100% faster on average, though of course, messages are very diverse, so if anyone would like to assist in the determination of true average speed advantages, feel free. I'd appreciate it.
    234 downloads
  4. 2.0.2Fixed all version incompatibilities above 1.6Oct 28, 2016
    Fixed version incompatibilities. Now tested for 1.6, 1.7, 1.8, 1.9, and 1.10 Refactored and simplified unaccessed areas of the source.
    204 downloads
  5. 1.1.2Added support for Spigot hack versionsDec 30, 2015
    The previous update of this API utilized apache's StringEscapeUtils for escaping unescaped json strings inputted by the user. The spigot hack is missing a lot of imports, including this one. This current version uses the JsonObject class, which is available in the spigot hack's imports, and will therefore work for both.
    111 downloads
  6. 1.1.1Added support for unescaped user inputsDec 28, 2015
    We all make mistakes. This update will help to catch yours, if you ever find yourself having inputted some unescaped text into the json builder.
    55 downloads
  7. 1.1.0Dec 27, 2015
    46 downloads

Similar projects

Plugin →