MC 1.16.1 compatibility

- Update Spigot and NBTAPI so that the plugin functions at all
- Update AnvilGUI so the search and permissions UIs work
- ask for SkullOwner instead of Owner, since the latter is no longer
  present
This commit is contained in:
B. Kelly 2020-07-17 14:40:16 -04:00 committed by B. Kelly
parent fdad6e099f
commit aab53b8909
4 changed files with 7 additions and 7 deletions

View File

@ -6,7 +6,7 @@
<groupId>net.seanomik</groupId>
<artifactId>energeticstorage</artifactId>
<version>0.2.1-SNAPSHOT</version>
<version>0.2.2-SNAPSHOT</version>
<packaging>jar</packaging>
<name>EnergeticStorage</name>
@ -101,19 +101,19 @@
<dependency>
<groupId>org.spigotmc</groupId>
<artifactId>spigot</artifactId>
<version>1.15.2-R0.1-SNAPSHOT</version>
<version>1.16.1-R0.1-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>de.tr7zw</groupId>
<artifactId>item-nbt-api</artifactId>
<version>2.3.0</version>
<version>2.4.1</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.github.WesJD.AnvilGUI</groupId>
<artifactId>anvilgui</artifactId>
<version>7a87a9dd65</version>
<version>ef71db62ecd6e14405eb7891d7d1c58341b9e61e</version>
</dependency>
</dependencies>
</project>

View File

@ -29,7 +29,7 @@ public class BlockBreakListener implements Listener {
Player player = event.getPlayer();
NBTTileEntity blockNBT = new NBTTileEntity(block.getState());
if (blockNBT.getCompound("Owner").getCompound("Properties").getCompoundList("textures").get(0).getString("Value").equals(Skulls.Computer.getTexture())) {
if (blockNBT.getCompound("SkullOwner").getCompound("Properties").getCompoundList("textures").get(0).getString("Value").equals(Skulls.Computer.getTexture())) {
ESSystem esSystem = Utils.findSystemAtLocation(block.getLocation());
if (esSystem != null) {

View File

@ -29,7 +29,7 @@ public class BlockPlaceListener implements Listener {
NBTTileEntity blockNBT = new NBTTileEntity(block.getState());
if (blockNBT.getCompound("Owner").getCompound("Properties").getCompoundList("textures").get(0).getString("Value").equals(Skulls.Computer.getTexture())) {
if (blockNBT.getCompound("SkullOwner").getCompound("Properties").getCompoundList("textures").get(0).getString("Value").equals(Skulls.Computer.getTexture())) {
if (PermissionChecks.canCreateSystem(player)) {
ESSystem newSystem = new ESSystem(player.getUniqueId(), UUID.randomUUID(), block.getLocation());
PlayersFile.savePlayerSystem(newSystem);

View File

@ -26,7 +26,7 @@ public class PlayerInteractListener implements Listener {
NBTTileEntity blockNBT = new NBTTileEntity(block.getState());
if (blockNBT.getCompound("Owner").getCompound("Properties").getCompoundList("textures").get(0).getString("Value").equals(Skulls.Computer.getTexture())) {
if (blockNBT.getCompound("SkullOwner").getCompound("Properties").getCompoundList("textures").get(0).getString("Value").equals(Skulls.Computer.getTexture())) {
event.setCancelled(true);
ESSystem esSystem = Utils.findSystemAtLocation(block.getLocation());