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:
parent
fdad6e099f
commit
aab53b8909
8
pom.xml
8
pom.xml
|
@ -6,7 +6,7 @@
|
||||||
|
|
||||||
<groupId>net.seanomik</groupId>
|
<groupId>net.seanomik</groupId>
|
||||||
<artifactId>energeticstorage</artifactId>
|
<artifactId>energeticstorage</artifactId>
|
||||||
<version>0.2.1-SNAPSHOT</version>
|
<version>0.2.2-SNAPSHOT</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<name>EnergeticStorage</name>
|
<name>EnergeticStorage</name>
|
||||||
|
@ -101,19 +101,19 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.spigotmc</groupId>
|
<groupId>org.spigotmc</groupId>
|
||||||
<artifactId>spigot</artifactId>
|
<artifactId>spigot</artifactId>
|
||||||
<version>1.15.2-R0.1-SNAPSHOT</version>
|
<version>1.16.1-R0.1-SNAPSHOT</version>
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>de.tr7zw</groupId>
|
<groupId>de.tr7zw</groupId>
|
||||||
<artifactId>item-nbt-api</artifactId>
|
<artifactId>item-nbt-api</artifactId>
|
||||||
<version>2.3.0</version>
|
<version>2.4.1</version>
|
||||||
<scope>compile</scope>
|
<scope>compile</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.github.WesJD.AnvilGUI</groupId>
|
<groupId>com.github.WesJD.AnvilGUI</groupId>
|
||||||
<artifactId>anvilgui</artifactId>
|
<artifactId>anvilgui</artifactId>
|
||||||
<version>7a87a9dd65</version>
|
<version>ef71db62ecd6e14405eb7891d7d1c58341b9e61e</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
</project>
|
</project>
|
||||||
|
|
|
@ -29,7 +29,7 @@ public class BlockBreakListener implements Listener {
|
||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
|
|
||||||
NBTTileEntity blockNBT = new NBTTileEntity(block.getState());
|
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());
|
ESSystem esSystem = Utils.findSystemAtLocation(block.getLocation());
|
||||||
|
|
||||||
if (esSystem != null) {
|
if (esSystem != null) {
|
||||||
|
|
|
@ -29,7 +29,7 @@ public class BlockPlaceListener implements Listener {
|
||||||
|
|
||||||
NBTTileEntity blockNBT = new NBTTileEntity(block.getState());
|
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)) {
|
if (PermissionChecks.canCreateSystem(player)) {
|
||||||
ESSystem newSystem = new ESSystem(player.getUniqueId(), UUID.randomUUID(), block.getLocation());
|
ESSystem newSystem = new ESSystem(player.getUniqueId(), UUID.randomUUID(), block.getLocation());
|
||||||
PlayersFile.savePlayerSystem(newSystem);
|
PlayersFile.savePlayerSystem(newSystem);
|
||||||
|
|
|
@ -26,7 +26,7 @@ public class PlayerInteractListener implements Listener {
|
||||||
|
|
||||||
NBTTileEntity blockNBT = new NBTTileEntity(block.getState());
|
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);
|
event.setCancelled(true);
|
||||||
|
|
||||||
ESSystem esSystem = Utils.findSystemAtLocation(block.getLocation());
|
ESSystem esSystem = Utils.findSystemAtLocation(block.getLocation());
|
||||||
|
|
Loading…
Reference in New Issue