diff --git a/build.gradle b/build.gradle index a155abedc..b0a4b47fe 100644 --- a/build.gradle +++ b/build.gradle @@ -40,7 +40,7 @@ allprojects { apply plugin: 'java' group = 'us.dynmap' - version = '3.7-SNAPSHOT' + version = '3.7-beta-5' } diff --git a/bukkit-helper-117/src/main/java/org/dynmap/bukkit/helper/v117/BukkitVersionHelperSpigot117.java b/bukkit-helper-117/src/main/java/org/dynmap/bukkit/helper/v117/BukkitVersionHelperSpigot117.java index f5a9b0764..cd9dbcd72 100644 --- a/bukkit-helper-117/src/main/java/org/dynmap/bukkit/helper/v117/BukkitVersionHelperSpigot117.java +++ b/bukkit-helper-117/src/main/java/org/dynmap/bukkit/helper/v117/BukkitVersionHelperSpigot117.java @@ -318,7 +318,7 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World w) { TileEntity tileent = (TileEntity) te; NBTTagCompound nbt = new NBTTagCompound(); tileent.save(nbt); // readNBT diff --git a/bukkit-helper-118-2/src/main/java/org/dynmap/bukkit/helper/v118_2/BukkitVersionHelperSpigot118_2.java b/bukkit-helper-118-2/src/main/java/org/dynmap/bukkit/helper/v118_2/BukkitVersionHelperSpigot118_2.java index fed30017d..82a0308cf 100644 --- a/bukkit-helper-118-2/src/main/java/org/dynmap/bukkit/helper/v118_2/BukkitVersionHelperSpigot118_2.java +++ b/bukkit-helper-118-2/src/main/java/org/dynmap/bukkit/helper/v118_2/BukkitVersionHelperSpigot118_2.java @@ -354,7 +354,7 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World w) { TileEntity tileent = (TileEntity) te; NBTTagCompound nbt = tileent.n(); return nbt; diff --git a/bukkit-helper-118/src/main/java/org/dynmap/bukkit/helper/v118/BukkitVersionHelperSpigot118.java b/bukkit-helper-118/src/main/java/org/dynmap/bukkit/helper/v118/BukkitVersionHelperSpigot118.java index fbacfa6dc..b7a89d0a4 100644 --- a/bukkit-helper-118/src/main/java/org/dynmap/bukkit/helper/v118/BukkitVersionHelperSpigot118.java +++ b/bukkit-helper-118/src/main/java/org/dynmap/bukkit/helper/v118/BukkitVersionHelperSpigot118.java @@ -347,7 +347,7 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World w) { TileEntity tileent = (TileEntity) te; NBTTagCompound nbt = tileent.n(); return nbt; diff --git a/bukkit-helper-119-3/src/main/java/org/dynmap/bukkit/helper/v119_3/BukkitVersionHelperSpigot119_3.java b/bukkit-helper-119-3/src/main/java/org/dynmap/bukkit/helper/v119_3/BukkitVersionHelperSpigot119_3.java index 93c5627ad..2cb2ac675 100644 --- a/bukkit-helper-119-3/src/main/java/org/dynmap/bukkit/helper/v119_3/BukkitVersionHelperSpigot119_3.java +++ b/bukkit-helper-119-3/src/main/java/org/dynmap/bukkit/helper/v119_3/BukkitVersionHelperSpigot119_3.java @@ -356,7 +356,7 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World w) { TileEntity tileent = (TileEntity) te; NBTTagCompound nbt = tileent.n(); return nbt; diff --git a/bukkit-helper-119-4/src/main/java/org/dynmap/bukkit/helper/v119_4/BukkitVersionHelperSpigot119_4.java b/bukkit-helper-119-4/src/main/java/org/dynmap/bukkit/helper/v119_4/BukkitVersionHelperSpigot119_4.java index b1591485d..fb62b90fe 100644 --- a/bukkit-helper-119-4/src/main/java/org/dynmap/bukkit/helper/v119_4/BukkitVersionHelperSpigot119_4.java +++ b/bukkit-helper-119-4/src/main/java/org/dynmap/bukkit/helper/v119_4/BukkitVersionHelperSpigot119_4.java @@ -364,7 +364,7 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World w) { TileEntity tileent = (TileEntity) te; NBTTagCompound nbt = tileent.n(); return nbt; diff --git a/bukkit-helper-119/src/main/java/org/dynmap/bukkit/helper/v119/BukkitVersionHelperSpigot119.java b/bukkit-helper-119/src/main/java/org/dynmap/bukkit/helper/v119/BukkitVersionHelperSpigot119.java index e6c27c316..621a3373d 100644 --- a/bukkit-helper-119/src/main/java/org/dynmap/bukkit/helper/v119/BukkitVersionHelperSpigot119.java +++ b/bukkit-helper-119/src/main/java/org/dynmap/bukkit/helper/v119/BukkitVersionHelperSpigot119.java @@ -354,7 +354,7 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World w) { TileEntity tileent = (TileEntity) te; NBTTagCompound nbt = tileent.n(); return nbt; diff --git a/bukkit-helper-120-2/src/main/java/org/dynmap/bukkit/helper/v120_2/BukkitVersionHelperSpigot120_2.java b/bukkit-helper-120-2/src/main/java/org/dynmap/bukkit/helper/v120_2/BukkitVersionHelperSpigot120_2.java index 372552171..0ea5d571c 100644 --- a/bukkit-helper-120-2/src/main/java/org/dynmap/bukkit/helper/v120_2/BukkitVersionHelperSpigot120_2.java +++ b/bukkit-helper-120-2/src/main/java/org/dynmap/bukkit/helper/v120_2/BukkitVersionHelperSpigot120_2.java @@ -362,7 +362,7 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World w) { TileEntity tileent = (TileEntity) te; NBTTagCompound nbt = tileent.n(); return nbt; diff --git a/bukkit-helper-120-4/src/main/java/org/dynmap/bukkit/helper/v120_4/BukkitVersionHelperSpigot120_4.java b/bukkit-helper-120-4/src/main/java/org/dynmap/bukkit/helper/v120_4/BukkitVersionHelperSpigot120_4.java index ca3968333..669c55d1c 100644 --- a/bukkit-helper-120-4/src/main/java/org/dynmap/bukkit/helper/v120_4/BukkitVersionHelperSpigot120_4.java +++ b/bukkit-helper-120-4/src/main/java/org/dynmap/bukkit/helper/v120_4/BukkitVersionHelperSpigot120_4.java @@ -362,7 +362,7 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World w) { TileEntity tileent = (TileEntity) te; NBTTagCompound nbt = tileent.o(); return nbt; diff --git a/bukkit-helper-120-5/src/main/java/org/dynmap/bukkit/helper/v120_5/BukkitVersionHelperSpigot120_5.java b/bukkit-helper-120-5/src/main/java/org/dynmap/bukkit/helper/v120_5/BukkitVersionHelperSpigot120_5.java index 3839fee2a..20d4af0f7 100644 --- a/bukkit-helper-120-5/src/main/java/org/dynmap/bukkit/helper/v120_5/BukkitVersionHelperSpigot120_5.java +++ b/bukkit-helper-120-5/src/main/java/org/dynmap/bukkit/helper/v120_5/BukkitVersionHelperSpigot120_5.java @@ -362,9 +362,11 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World w) { TileEntity tileent = (TileEntity) te; - NBTTagCompound nbt = new NBTTagCompound(); //TODO tileent.o(); + CraftWorld cw = (CraftWorld) w; + //NBTTagCompound nbt = tileent.o(world.registrtAccess()); + NBTTagCompound nbt = tileent.e(cw.getHandle().H_()); return nbt; } diff --git a/bukkit-helper-120/src/main/java/org/dynmap/bukkit/helper/v120/BukkitVersionHelperSpigot120.java b/bukkit-helper-120/src/main/java/org/dynmap/bukkit/helper/v120/BukkitVersionHelperSpigot120.java index 1463776b7..d473dfd3d 100644 --- a/bukkit-helper-120/src/main/java/org/dynmap/bukkit/helper/v120/BukkitVersionHelperSpigot120.java +++ b/bukkit-helper-120/src/main/java/org/dynmap/bukkit/helper/v120/BukkitVersionHelperSpigot120.java @@ -362,7 +362,7 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World world) { TileEntity tileent = (TileEntity) te; NBTTagCompound nbt = tileent.n(); return nbt; diff --git a/bukkit-helper/.project b/bukkit-helper/.project index 33f7105ef..f654b6b0a 100644 --- a/bukkit-helper/.project +++ b/bukkit-helper/.project @@ -2,35 +2,32 @@ Dynmap(Spigot-Common) bukkit-helper - - + + + org.eclipse.jdt.core.javanature + org.eclipse.m2e.core.maven2Nature + org.eclipse.buildship.core.gradleprojectnature + org.eclipse.jdt.core.javabuilder - - + org.eclipse.buildship.core.gradleprojectbuilder - - + org.eclipse.m2e.core.maven2Builder - - + - - org.eclipse.jdt.core.javanature - org.eclipse.m2e.core.maven2Nature - org.eclipse.buildship.core.gradleprojectnature - + 1 - 30 + org.eclipse.core.resources.regexFilterMatcher node_modules|\.git|__CREATED_BY_JAVA_LANGUAGE_SERVER__ diff --git a/bukkit-helper/.settings/org.eclipse.buildship.core.prefs b/bukkit-helper/.settings/org.eclipse.buildship.core.prefs index b476a285d..02e6009ac 100644 --- a/bukkit-helper/.settings/org.eclipse.buildship.core.prefs +++ b/bukkit-helper/.settings/org.eclipse.buildship.core.prefs @@ -2,7 +2,7 @@ arguments= auto.sync=false build.scans.enabled=false connection.gradle.distribution=GRADLE_DISTRIBUTION(VERSION(6.3)) -connection.project.dir=../bukkit-helper-120-2 +connection.project.dir=../bukkit-helper-120-5 eclipse.preferences.version=1 gradle.user.home= java.home=/Library/Java/JavaVirtualMachines/jdk1.8.0_251.jdk/Contents/Home diff --git a/bukkit-helper/.settings/org.eclipse.jdt.core.prefs b/bukkit-helper/.settings/org.eclipse.jdt.core.prefs index ccf02c1b6..57dfcdce7 100644 --- a/bukkit-helper/.settings/org.eclipse.jdt.core.prefs +++ b/bukkit-helper/.settings/org.eclipse.jdt.core.prefs @@ -1,5 +1,5 @@ # -#Fri Apr 26 17:37:35 CDT 2024 +#Sun Apr 28 13:34:57 CDT 2024 eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.annotation.nonnull=javax.annotation.Nonnull org.eclipse.jdt.core.compiler.annotation.nullable=javax.annotation.Nullable diff --git a/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/AbstractMapChunkCache.java b/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/AbstractMapChunkCache.java index 794490fb4..d81022594 100644 --- a/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/AbstractMapChunkCache.java +++ b/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/AbstractMapChunkCache.java @@ -900,7 +900,7 @@ else if(hidestyle == HiddenChunkStyle.FILL_OCEAN) String[] te_fields = HDBlockModels.getTileEntityFieldsNeeded(ss.getBlockType(cx, te_y, cz)); if(te_fields != null) { //Object nbtcompound = BukkitVersionHelper.helper.readTileEntityNBT(t); - Object nbtcompound = BukkitVersionHelper.helper.readTileEntityNBT(t); + Object nbtcompound = BukkitVersionHelper.helper.readTileEntityNBT(t, this.w); vals.clear(); for(String id: te_fields) { Object val = BukkitVersionHelper.helper.getFieldValue(nbtcompound, id); diff --git a/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelper.java b/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelper.java index 58cdb90d0..04b99f9f2 100644 --- a/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelper.java +++ b/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelper.java @@ -101,7 +101,7 @@ protected BukkitVersionHelper() { /** * Read tile entity NBT */ - public abstract Object readTileEntityNBT(Object te); + public abstract Object readTileEntityNBT(Object te, World world); /** * Get field value from NBT compound */ diff --git a/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelperGeneric.java b/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelperGeneric.java index edb0faf82..15bdb73bc 100644 --- a/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelperGeneric.java +++ b/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelperGeneric.java @@ -24,6 +24,7 @@ import com.google.gson.GsonBuilder; import com.google.gson.JsonParseException; + /** * Helper for isolation of bukkit version specific issues */ @@ -456,7 +457,8 @@ public int getTileEntityZ(Object te) { /** * Read tile entity NBT */ - public Object readTileEntityNBT(Object te) { + @Override + public Object readTileEntityNBT(Object te, org.bukkit.World w) { if(nbttagcompound == null) return null; Object nbt = null; try { diff --git a/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelperGlowstone.java b/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelperGlowstone.java index 926292360..033c49639 100644 --- a/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelperGlowstone.java +++ b/bukkit-helper/src/main/java/org/dynmap/bukkit/helper/BukkitVersionHelperGlowstone.java @@ -127,7 +127,7 @@ public int getTileEntityZ(Object te) { } @Override - public Object readTileEntityNBT(Object te) { + public Object readTileEntityNBT(Object te, org.bukkit.World w) { // TODO Auto-generated method stub return null; }