mirror of
https://github.com/PSYCHEER/VanillaCustomizer.git
synced 2025-12-19 15:09:17 +00:00
Fixed conflict
[eco] Exception in packet listener com.willfp.eco.internal.spigot.proxy.v1_21_4.common.packet.display.PacketWindowItems for packet net.minecraft.network.protocol.game.ClientboundContainerSetContentPacket! [15:52:44 WARN]: java.lang.ClassCastException: class java.lang.String cannot be cast to class net.minecraft.network.chat.Component (java.lang.String is in module java.base of loader 'bootstrap'; net.minecraft.network.chat.Component is in unnamed module of loader java.net.URLClassLoader @5e91993f) ...
This commit is contained in:
@@ -90,6 +90,12 @@
|
||||
<version>24.0.0</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>ca.bkaw</groupId>
|
||||
<artifactId>paper-nms</artifactId>
|
||||
<version>1.21.4-SNAPSHOT</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
|
||||
@@ -45,14 +45,14 @@ public class LoreInsert implements IChange
|
||||
int i = index;
|
||||
for (String line : lines)
|
||||
{
|
||||
loreNMS.add(i, Utils.legacyToNMS(IChange.replacePlaceholders(session, line)));
|
||||
loreNMS.add(i, Utils.jsonToNMS(IChange.replacePlaceholders(session, line)));
|
||||
i++;
|
||||
}
|
||||
}
|
||||
else // If it's out of bounds I just append at the end.
|
||||
{
|
||||
for (String line : lines)
|
||||
loreNMS.add(Comp.legacyToJson(IChange.replacePlaceholders(session, line)));
|
||||
loreNMS.add(Utils.jsonToNMS(IChange.replacePlaceholders(session, line)));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -101,11 +101,11 @@ public class LoreInsert implements IChange
|
||||
if (loreNMS == null)
|
||||
{
|
||||
loreNMS = new ArrayList<>();
|
||||
loreNMS.add(Utils.legacyToNMS(line));
|
||||
loreNMS.add(Utils.jsonToNMS(line));
|
||||
}
|
||||
else
|
||||
{
|
||||
loreNMS.add(index, Utils.legacyToNMS(line));
|
||||
loreNMS.add(index, Utils.jsonToNMS(line));
|
||||
}
|
||||
|
||||
nbt.setLore(loreNMS);
|
||||
|
||||
@@ -2,7 +2,6 @@ package dev.lone.vanillacustomizer.utils;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import dev.lone.vanillacustomizer.Main;
|
||||
import dev.lone.vanillacustomizer.nms.NMS;
|
||||
import org.apache.commons.io.FileUtils;
|
||||
import org.apache.commons.lang.Validate;
|
||||
import org.bukkit.Bukkit;
|
||||
@@ -30,6 +29,11 @@ import java.util.regex.Pattern;
|
||||
/**
|
||||
* 2020-01-08 LoneDev
|
||||
*/
|
||||
|
||||
/**
|
||||
* 2025-02-16 PSYCHEER
|
||||
*/
|
||||
|
||||
@SuppressWarnings("unused")
|
||||
public class ConfigFile
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user