Aim: My aim in this project is to create a EULA compliant perk to entice donations to my network. I will call it Syntax Tags. Syntax Tags is a plugin I will be working on using a command ("/tags") to open a GUI showing tags available to the player. This will all be permission based so "biast.tag.winner" would be for [Winner] suffix in chat. On clocking the tag it should either disable if the tag is enabled or enable if the tag is disabled. It will only add the tag item to the GUI if you have a permission. How I'm thinking: I am going to use a boolean for every tag so for example (boolean winnerBoolean = false by default. I will create the item as an item stack per tag and add to the inventory if the player has permission for the tag. I will then use ASyncChatEvent to set the message format removing or adding the suffix. Questions How would I go about implementing the chat without disforming essentials chat formatting or pex groups.
Best way to do it is just store the player names and what tag they have active in a map, then you can call and change it from that using the inventory click event get item and get item name.
I think that the best way would be to set metadata of the tag on the player so you don't have lookup times pulling from the map.
Event.setformat(event.getformat().replaceall("%tag%", getTag())); Something like that should work, just put in your essentials format that tag where you want it to be
Not really because I need to place something after the player name, I would like to maybe add a placeholder in essentials config but have no idea how to do it
Well you can just add %yourplaceholder% then in the chat event use .replaceAll(%yourplaceholder%, value);