diff --git a/api/src/main/java/com/alttd/chat/objects/ChatUser.java b/api/src/main/java/com/alttd/chat/objects/ChatUser.java index b960846..960b930 100755 --- a/api/src/main/java/com/alttd/chat/objects/ChatUser.java +++ b/api/src/main/java/com/alttd/chat/objects/ChatUser.java @@ -15,7 +15,7 @@ public class ChatUser { private String staffPrefix; // doesn't need saving, we get this from luckperms private String prefixAll; // doesn't need saving, we get this from luckperms private boolean toggleGc; // should be saved, this toggles if the player can see and use global chat - private UUID replyTarget; // reply target for use in /msg i don't mind setting this to null on login, feedback? + private String replyTarget; // reply target for use in /msg i don't mind setting this to null on login, feedback? private long gcCooldown; // the time when they last used gc, is used for the cooldown, i wouldn't save this, but setting this to the login time means they can't use gc for 30 seconds after logging in private LinkedList mails; // mails aren't finalized yet, so for now a table sender, reciever, sendtime, readtime(if emtpy mail isn't read yet?, could also do a byte to control this), the actual message @@ -102,11 +102,11 @@ public class ChatUser { return toggleGc; } - public UUID getReplyTarget() { + public String getReplyTarget() { return replyTarget; } - public void setReplyTarget(UUID replyTarget) { + public void setReplyTarget(String replyTarget) { this.replyTarget = replyTarget; } diff --git a/galaxy/dependency-reduced-pom.xml b/galaxy/dependency-reduced-pom.xml index 2640e9b..8a881ee 100644 --- a/galaxy/dependency-reduced-pom.xml +++ b/galaxy/dependency-reduced-pom.xml @@ -67,7 +67,7 @@ - 16 - 16 + 11 + 11 diff --git a/galaxy/src/main/java/com/alttd/chat/handler/ChatHandler.java b/galaxy/src/main/java/com/alttd/chat/handler/ChatHandler.java index c3b9d20..be61b63 100755 --- a/galaxy/src/main/java/com/alttd/chat/handler/ChatHandler.java +++ b/galaxy/src/main/java/com/alttd/chat/handler/ChatHandler.java @@ -37,10 +37,7 @@ public class ChatHandler { public void privateMessage(Player player, String target, String message) { ChatUser user = ChatUserManager.getChatUser(player.getUniqueId()); - - Component senderName = player.displayName(); - String prefix = user.getPrefix(); - + user.setReplyTarget(target); message = RegexManager.replaceText(message); // todo a better way for this if(message == null) return; // the message was blocked diff --git a/galaxy/src/main/resources/plugin.yml b/galaxy/src/main/resources/plugin.yml index f7aeeca..b19ad49 100755 --- a/galaxy/src/main/resources/plugin.yml +++ b/galaxy/src/main/resources/plugin.yml @@ -8,4 +8,10 @@ commands: globalchat: permission: command.globalchat permission-message: You do not have permission! - aliases: gc \ No newline at end of file + aliases: gc + message: + permission: command.message + aliases: msg + reply: + permission: command.message + aliases: r \ No newline at end of file