Update to 2.4.24

This commit is contained in:
GeorgH93 2023-12-04 02:21:11 +01:00
parent bb7776b065
commit 0c9ef35e36
No known key found for this signature in database
GPG Key ID: D1630D37F9E4B3C8
3 changed files with 11 additions and 6 deletions

View File

@ -20,10 +20,12 @@
import at.pcgamingfreaks.Bukkit.ItemStackSerializer.ItemStackSerializer;
import at.pcgamingfreaks.Bukkit.MCVersion;
import at.pcgamingfreaks.ConsoleColor;
import lombok.Getter;
import org.bukkit.inventory.Inventory;
import org.bukkit.inventory.ItemStack;
import java.util.logging.Level;
import java.util.logging.Logger;
public class InventorySerializer
@ -49,13 +51,16 @@ public InventorySerializer(Logger logger)
}
catch(Exception e)
{
e.printStackTrace();
logger.log(Level.SEVERE, "Failed to produce serializer!", e);
}
if(serializer == null)
{
logger.severe("NBTItemStackSerializer does not support your Minecraft version!\nFalling back to BukkitItemStackSerializer! This most likely is wrong!");
usedSerializer = 0;
serializer = BUKKIT_ITEM_STACK_SERIALIZER;
if (MCVersion.isOlderThan(MCVersion.MC_NMS_1_8_R1))
{
usedSerializer = 0;
serializer = BUKKIT_ITEM_STACK_SERIALIZER;
}
}
this.serializer = serializer;
this.usedSerializer = usedSerializer;

View File

@ -126,7 +126,7 @@ public void onEnable()
private boolean checkMcVersion()
{
if(MCVersion.is(MCVersion.UNKNOWN) || !MCVersion.isUUIDsSupportAvailable() || MCVersion.isNewerThan(MCVersion.MC_NMS_1_20_R2))
if(MCVersion.is(MCVersion.UNKNOWN) || !MCVersion.isUUIDsSupportAvailable() || MCVersion.isNewerThan(MCVersion.MC_NMS_1_20_R3))
{
this.warnOnVersionIncompatibility();
this.setEnabled(false);

View File

@ -7,13 +7,13 @@
<packaging>pom</packaging>
<properties>
<revision>2.4.24-SNAPSHOT</revision>
<revision>2.4.24</revision>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<configFileVersion>34</configFileVersion>
<languageFileVersion>20</languageFileVersion>
<pcgfPluginLibVersion>1.0.39.2-SNAPSHOT</pcgfPluginLibVersion>
<pcgfPluginLibVersion>1.0.39.3-SNAPSHOT</pcgfPluginLibVersion>
<bukkitVersion>1.15.2-R0.1-SNAPSHOT</bukkitVersion>
<mavenShade.version>3.4.1</mavenShade.version>