aboutsummaryrefslogtreecommitdiffhomepage
path: root/patch-remap/og/net/minecraft/server/gui/ServerGUI.patch
diff options
context:
space:
mode:
authorMiniDigger | Martin <[email protected]>2024-01-14 11:04:49 +0100
committerMiniDigger | Martin <[email protected]>2024-01-14 11:04:49 +0100
commitbee74680e607c2e29b038329f62181238911cd83 (patch)
tree708fd1a4a0227d9071243adf2a42d5e9e96cde4a /patch-remap/og/net/minecraft/server/gui/ServerGUI.patch
parent0a44692ef6ff6e255d48eb3ba1bb114166eafda9 (diff)
downloadPaper-bee74680e607c2e29b038329f62181238911cd83.tar.gz
Paper-bee74680e607c2e29b038329f62181238911cd83.zip
add remapped patches as a testsoftspoon
Diffstat (limited to 'patch-remap/og/net/minecraft/server/gui/ServerGUI.patch')
-rw-r--r--patch-remap/og/net/minecraft/server/gui/ServerGUI.patch28
1 files changed, 28 insertions, 0 deletions
diff --git a/patch-remap/og/net/minecraft/server/gui/ServerGUI.patch b/patch-remap/og/net/minecraft/server/gui/ServerGUI.patch
new file mode 100644
index 0000000000..5c6b09ab35
--- /dev/null
+++ b/patch-remap/og/net/minecraft/server/gui/ServerGUI.patch
@@ -0,0 +1,28 @@
+--- a/net/minecraft/server/gui/ServerGUI.java
++++ b/net/minecraft/server/gui/ServerGUI.java
+@@ -96,7 +96,7 @@
+ private JComponent buildInfoPanel() {
+ JPanel jpanel = new JPanel(new BorderLayout());
+ GuiStatsComponent guistatscomponent = new GuiStatsComponent(this.server);
+- Collection collection = this.finalizers;
++ Collection<Runnable> collection = this.finalizers; // CraftBukkit - decompile error
+
+ Objects.requireNonNull(guistatscomponent);
+ collection.add(guistatscomponent::close);
+@@ -166,6 +166,7 @@
+ this.finalizers.forEach(Runnable::run);
+ }
+
++ private static final java.util.regex.Pattern ANSI = java.util.regex.Pattern.compile("\\x1B\\[([0-9]{1,2}(;[0-9]{1,2})*)?[m|K]"); // CraftBukkit
+ public void print(JTextArea jtextarea, JScrollPane jscrollpane, String s) {
+ if (!SwingUtilities.isEventDispatchThread()) {
+ SwingUtilities.invokeLater(() -> {
+@@ -181,7 +182,7 @@
+ }
+
+ try {
+- document.insertString(document.getLength(), s, (AttributeSet) null);
++ document.insertString(document.getLength(), ANSI.matcher(s).replaceAll(""), (AttributeSet) null); // CraftBukkit
+ } catch (BadLocationException badlocationexception) {
+ ;
+ }