Skip to content

Commit 3d1b085

Browse files
committed
actually fix my mistake of accidentally pulling to 1.19 branch instead of 1.18
(will probably have some problems when porting the next pull request, but that's future me's problem)
1 parent bace810 commit 3d1b085

File tree

3 files changed

+4
-6
lines changed

3 files changed

+4
-6
lines changed

src/main/java/io/github/techstreet/dfscript/screen/script/ScriptAddArgumentScreen.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public ScriptAddArgumentScreen(Script script, ScriptAction action, int index) {
4343
.fillStyle(Style.EMPTY.withItalic(false)));
4444

4545
ItemStack configValueIcon = new ItemStack(Items.INK_SAC);
46-
configValueIcon.setCustomName(new LiteralText("Config Value")
46+
configValueIcon.setCustomName(Text.literal("Config Value")
4747
.fillStyle(Style.EMPTY.withItalic(false)));
4848

4949

src/main/java/io/github/techstreet/dfscript/script/options/ScriptNamedOption.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
import io.github.techstreet.dfscript.util.chat.ChatUtil;
1010
import net.minecraft.client.util.InputUtil;
1111
import net.minecraft.item.ItemStack;
12-
import net.minecraft.text.LiteralText;
1312
import net.minecraft.text.Style;
1413
import net.minecraft.text.Text;
1514

@@ -49,7 +48,7 @@ public void setName(String text) {
4948
}
5049

5150
public ItemStack getIcon() {
52-
return new ItemStack(option.getIcon()).setCustomName(new LiteralText(getName()).fillStyle(Style.EMPTY.withItalic(false)));
51+
return new ItemStack(option.getIcon()).setCustomName(Text.literal(getName()).fillStyle(Style.EMPTY.withItalic(false)));
5352
}
5453

5554
public static class Serializer implements JsonSerializer<ScriptNamedOption>, JsonDeserializer<ScriptNamedOption> {

src/main/java/io/github/techstreet/dfscript/script/options/ScriptOptionEnum.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
import net.minecraft.nbt.NbtElement;
88
import net.minecraft.nbt.NbtList;
99
import net.minecraft.nbt.NbtString;
10-
import net.minecraft.text.LiteralText;
1110
import net.minecraft.text.Style;
1211
import net.minecraft.text.Text;
1312
import net.minecraft.util.Formatting;
@@ -36,11 +35,11 @@ public ItemStack getIcon()
3635
{
3736
ItemStack item = new ItemStack(icon);
3837

39-
item.setCustomName(new LiteralText(name).fillStyle(Style.EMPTY.withColor(Formatting.WHITE).withItalic(false)));
38+
item.setCustomName(Text.literal(name).fillStyle(Style.EMPTY.withColor(Formatting.WHITE).withItalic(false)));
4039

4140
NbtList lore = new NbtList();
4241

43-
lore.add(NbtString.of(Text.Serializer.toJson(new LiteralText(description)
42+
lore.add(NbtString.of(Text.Serializer.toJson(Text.literal(description)
4443
.fillStyle(Style.EMPTY.withColor(Formatting.GRAY).withItalic(false))
4544
)));
4645

0 commit comments

Comments
 (0)