Closed ghost closed 7 years ago
Is there a method provided by the API that turns styled MC text into its plain text?
E.g. I'd like to be able to
public void onActionBar(ActionBarEvent event) { message = event.getVerbatimMessage(); // returning "hey" instead of "§chey" for example }
Yes, just call eu.the5zig.util.minecraft.ChatColor.stripColor(String). It returns the text without the §-color codes
eu.the5zig.util.minecraft.ChatColor.stripColor(String)
§
Is there a method provided by the API that turns styled MC text into its plain text?
E.g. I'd like to be able to