allow {PRIORITY} placeholder in priority messages

This commit is contained in:
ajgeiss0702
2021-08-08 16:07:11 -07:00
parent 8e61a3b1e5
commit 4353341881
2 changed files with 2 additions and 2 deletions
@@ -152,7 +152,7 @@ public class QueueManagerImpl implements QueueManager {
String level = parts[0]; String level = parts[0];
String messageRaw = parts[1]; String messageRaw = parts[1];
if((level.equals("*") && queuePlayer.getPriority() > 0) || level.equals(queuePlayer.getPriority()+"")) { if((level.equals("*") && queuePlayer.getPriority() > 0) || level.equals(queuePlayer.getPriority()+"")) {
player.sendMessage(main.getMessages().toComponent(messageRaw)); player.sendMessage(main.getMessages().toComponent(messageRaw.replaceAll("\\{PRIORITY}", queuePlayer.getPriority()+"")));
} }
} }
} }
+1 -1
View File
@@ -188,5 +188,5 @@ enable-priority-messages: false
# The format is <priority>:<message> # The format is <priority>:<message>
# Example: 1:You have a priority of 1! # Example: 1:You have a priority of 1!
priority-messages: priority-messages:
- "*:<green>Joining the queue with priority!" - "*:<green>Joining the queue with a priority of {PRIORITY}!"
- "100:<yellow>Wow! You have a priority of 100!" - "100:<yellow>Wow! You have a priority of 100!"