More compilation error fixes
This commit is contained in:
@@ -41,8 +41,10 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
+import net.kyori.adventure.text.TextComponent;
|
||||
+import net.kyori.adventure.text.serializer.gson.GsonComponentSerializer;
|
||||
+import net.kyori.adventure.text.serializer.plain.PlainTextComponentSerializer;
|
||||
+import net.minecraft.network.chat.ComponentContents;
|
||||
+import net.minecraft.network.chat.MutableComponent;
|
||||
+import net.minecraft.network.chat.Style;
|
||||
+import net.minecraft.network.chat.contents.LiteralContents;
|
||||
+import net.minecraft.util.FormattedCharSequence;
|
||||
+import org.checkerframework.checker.nullness.qual.MonotonicNonNull;
|
||||
+import org.jetbrains.annotations.Nullable;
|
||||
@@ -74,9 +76,9 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
+ }
|
||||
+
|
||||
+ @Override
|
||||
+ public String getContents() {
|
||||
+ public ComponentContents getContents() {
|
||||
+ if (this.adventure instanceof TextComponent) {
|
||||
+ return ((TextComponent) this.adventure).content();
|
||||
+ return new LiteralContents(((TextComponent) this.adventure).content());
|
||||
+ } else {
|
||||
+ return this.deepConverted().getContents();
|
||||
+ }
|
||||
|
||||
Reference in New Issue
Block a user