Add support for hovers in chat and update default config
This commit is contained in:
parent
32f323ff41
commit
76c24828dd
|
|
@ -203,7 +203,7 @@ public final class Config {
|
|||
}
|
||||
|
||||
// TODO prefixes need hovers, this hasn't been setup yet!
|
||||
public static String CHATFORMAT = "<white><light_purple><prefixall> <gray><sender>: <white><message>";
|
||||
public static String CHATFORMAT = "<white><light_purple><prefixall> <gray><hover:show_text:Click to message <sendername>><click:suggest_command:/msg <sendername> ><sender></hover>: <white><message>";
|
||||
private static void Chat() {
|
||||
CHATFORMAT = getString("chat.format", CHATFORMAT);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -18,8 +18,8 @@ public class Utility {
|
|||
public static HashMap<String, String> colors;
|
||||
static { // this might be in minimessage already?
|
||||
colors = new HashMap<>();
|
||||
colors.put("&0", "<black>"); // and confirm these are correct
|
||||
colors.put("&1", "<dark_blue>"); // could also add some default hex colors here?
|
||||
colors.put("&0", "<black>");
|
||||
colors.put("&1", "<dark_blue>");
|
||||
colors.put("&2", "<dark_green>");
|
||||
colors.put("&3", "<dark_aqua>");
|
||||
colors.put("&4", "<dark_red>");
|
||||
|
|
|
|||
|
|
@ -93,6 +93,7 @@ public class ChatListener implements Listener, ChatRenderer {
|
|||
|
||||
List<Template> templates = new ArrayList<>(List.of(
|
||||
Template.of("sender", user.getDisplayName()),
|
||||
Template.of("sendername", player.getName()),
|
||||
Template.of("prefix", user.getPrefix()),
|
||||
Template.of("prefixall", user.getPrefixAll()),
|
||||
Template.of("staffprefix", user.getStaffPrefix()),
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user