mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-17 16:37:43 +01:00
Purpur config files
This commit is contained in:
committed by
granny
parent
e35e614ec8
commit
0813a32106
@@ -0,0 +1,33 @@
|
||||
--- a/net/minecraft/commands/CommandSourceStack.java
|
||||
+++ b/net/minecraft/commands/CommandSourceStack.java
|
||||
@@ -517,6 +_,30 @@
|
||||
}
|
||||
}
|
||||
|
||||
+ // Purpur start - Purpur config files
|
||||
+ public void sendSuccess(@Nullable String message) {
|
||||
+ sendSuccess(message, false);
|
||||
+ }
|
||||
+
|
||||
+ public void sendSuccess(@Nullable String message, boolean broadcastToOps) {
|
||||
+ if (message == null) {
|
||||
+ return;
|
||||
+ }
|
||||
+ sendSuccess(net.kyori.adventure.text.minimessage.MiniMessage.miniMessage().deserialize(message), broadcastToOps);
|
||||
+ }
|
||||
+
|
||||
+ public void sendSuccess(@Nullable net.kyori.adventure.text.Component message) {
|
||||
+ sendSuccess(message, false);
|
||||
+ }
|
||||
+
|
||||
+ public void sendSuccess(@Nullable net.kyori.adventure.text.Component message, boolean broadcastToOps) {
|
||||
+ if (message == null) {
|
||||
+ return;
|
||||
+ }
|
||||
+ sendSuccess(() -> io.papermc.paper.adventure.PaperAdventure.asVanilla(message), broadcastToOps);
|
||||
+ }
|
||||
+ // Purpur end - Purpur config files
|
||||
+
|
||||
public void sendSuccess(Supplier<Component> messageSupplier, boolean allowLogging) {
|
||||
boolean flag = this.source.acceptsSuccess() && !this.silent;
|
||||
boolean flag1 = allowLogging && this.source.shouldInformAdmins() && !this.silent;
|
||||
Reference in New Issue
Block a user