From be8e2e4f902e39ea66f3e874c1ebf9d57b745dd8 Mon Sep 17 00:00:00 2001 From: Lixfel Date: Fri, 20 Dec 2019 21:31:42 +0100 Subject: [PATCH] First 1.15 support --- .../pom.xml | 4 +-- .../schematicsystem/CheckSchemType_15.java | 32 +++++++++++++++---- .../schematicsystem/WorldEdit_15.java | 4 +-- SchematicSystem_Main/pom.xml | 2 +- .../schematicsystem/CheckSchemType.java | 4 +-- .../steamwar/schematicsystem/WorldEdit.java | 4 +-- pom.xml | 2 +- 7 files changed, 35 insertions(+), 17 deletions(-) rename {SchematicSystem_14 => SchematicSystem_15}/pom.xml (93%) rename SchematicSystem_14/src/de/steamwar/schematicsystem/CheckSchemType_14.java => SchematicSystem_15/src/de/steamwar/schematicsystem/CheckSchemType_15.java (87%) rename SchematicSystem_14/src/de/steamwar/schematicsystem/WorldEdit_14.java => SchematicSystem_15/src/de/steamwar/schematicsystem/WorldEdit_15.java (97%) diff --git a/SchematicSystem_14/pom.xml b/SchematicSystem_15/pom.xml similarity index 93% rename from SchematicSystem_14/pom.xml rename to SchematicSystem_15/pom.xml index 746d6d8..6bee056 100644 --- a/SchematicSystem_14/pom.xml +++ b/SchematicSystem_15/pom.xml @@ -4,7 +4,7 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 - SchematicSystem_14 + SchematicSystem_15 1.0 @@ -35,7 +35,7 @@ steamwar Spigot - 1.14 + 1.15 provided diff --git a/SchematicSystem_14/src/de/steamwar/schematicsystem/CheckSchemType_14.java b/SchematicSystem_15/src/de/steamwar/schematicsystem/CheckSchemType_15.java similarity index 87% rename from SchematicSystem_14/src/de/steamwar/schematicsystem/CheckSchemType_14.java rename to SchematicSystem_15/src/de/steamwar/schematicsystem/CheckSchemType_15.java index b778591..a9bf3e4 100644 --- a/SchematicSystem_14/src/de/steamwar/schematicsystem/CheckSchemType_14.java +++ b/SchematicSystem_15/src/de/steamwar/schematicsystem/CheckSchemType_15.java @@ -16,7 +16,7 @@ import java.util.List; import java.util.Set; import java.util.logging.Level; -class CheckSchemType_14 { +class CheckSchemType_15 { private static final Set INVENTORY = EnumSet.of( Material.CHEST, Material.TRAPPED_CHEST, @@ -42,13 +42,31 @@ class CheckSchemType_14 { Material.LIME_SHULKER_BOX, Material.MAGENTA_SHULKER_BOX, Material.PINK_SHULKER_BOX, - Material.PURPLE_SHULKER_BOX); - //TODO: New Inventory Items - //TODO: Adding flowers - private static final Set FLOWERS = EnumSet.of( - Material.CORNFLOWER); + Material.PURPLE_SHULKER_BOX, + Material.LECTERN, + Material.BEACON, + Material.BARREL); - private CheckSchemType_14(){} + private static final Set FLOWERS = EnumSet.of( + Material.CORNFLOWER, + Material.FERN, + Material.DANDELION, + Material.POPPY, + Material.BLUE_ORCHID, + Material.ALLIUM, + Material.AZURE_BLUET, + Material.RED_TULIP, + Material.ORANGE_TULIP, + Material.WHITE_TULIP, + Material.PINK_TULIP, + Material.OXEYE_DAISY, + Material.CORNFLOWER, + Material.LILY_OF_THE_VALLEY, + Material.WITHER_ROSE, + Material.BROWN_MUSHROOM, + Material.RED_MUSHROOM); + + private CheckSchemType_15(){} static void autoCheck(Schematic schematic, List errors, List warnings, ICheckSchemType type) { Clipboard clipboard; diff --git a/SchematicSystem_14/src/de/steamwar/schematicsystem/WorldEdit_14.java b/SchematicSystem_15/src/de/steamwar/schematicsystem/WorldEdit_15.java similarity index 97% rename from SchematicSystem_14/src/de/steamwar/schematicsystem/WorldEdit_14.java rename to SchematicSystem_15/src/de/steamwar/schematicsystem/WorldEdit_15.java index 6d3336b..5dae94a 100644 --- a/SchematicSystem_14/src/de/steamwar/schematicsystem/WorldEdit_14.java +++ b/SchematicSystem_15/src/de/steamwar/schematicsystem/WorldEdit_15.java @@ -16,8 +16,8 @@ import org.bukkit.entity.Player; import java.io.IOException; -class WorldEdit_14 { - private WorldEdit_14(){} +class WorldEdit_15 { + private WorldEdit_15(){} static EditSession pasteSchematic(Player player, Schematic schematic) throws Schematic.WrongVersionException, IOException, NoClipboardException { World weWorld = new BukkitWorld(player.getWorld()); diff --git a/SchematicSystem_Main/pom.xml b/SchematicSystem_Main/pom.xml index d65b137..8c1a28b 100644 --- a/SchematicSystem_Main/pom.xml +++ b/SchematicSystem_Main/pom.xml @@ -64,7 +64,7 @@ steamwar - SchematicSystem_14 + SchematicSystem_15 1.0 compile diff --git a/SchematicSystem_Main/src/de/steamwar/schematicsystem/CheckSchemType.java b/SchematicSystem_Main/src/de/steamwar/schematicsystem/CheckSchemType.java index de6f1ba..dd94a92 100644 --- a/SchematicSystem_Main/src/de/steamwar/schematicsystem/CheckSchemType.java +++ b/SchematicSystem_Main/src/de/steamwar/schematicsystem/CheckSchemType.java @@ -60,8 +60,8 @@ public class CheckSchemType implements ICheckSchemType { public void autoCheck(Schematic schematic, List errors, List warnings) { switch(Core.getVersion()){ - case 14: - CheckSchemType_14.autoCheck(schematic, errors, warnings, this); + case 15: + CheckSchemType_15.autoCheck(schematic, errors, warnings, this); break; default: CheckSchemType_12.autoCheck(schematic, errors, warnings, this); diff --git a/SchematicSystem_Main/src/de/steamwar/schematicsystem/WorldEdit.java b/SchematicSystem_Main/src/de/steamwar/schematicsystem/WorldEdit.java index f7ac14f..06a6fb0 100644 --- a/SchematicSystem_Main/src/de/steamwar/schematicsystem/WorldEdit.java +++ b/SchematicSystem_Main/src/de/steamwar/schematicsystem/WorldEdit.java @@ -13,8 +13,8 @@ public class WorldEdit { public static EditSession pasteSchematic(Player player, Schematic schematic) throws Schematic.WrongVersionException, IOException, NoClipboardException { switch(Core.getVersion()){ - case 14: - return WorldEdit_14.pasteSchematic(player, schematic); + case 15: + return WorldEdit_15.pasteSchematic(player, schematic); default: return WorldEdit_12.pasteSchematic(player, schematic); } diff --git a/pom.xml b/pom.xml index 8cf978c..6bef6fd 100644 --- a/pom.xml +++ b/pom.xml @@ -37,7 +37,7 @@ SchematicSystem_12 - SchematicSystem_14 + SchematicSystem_15 SchematicSystem_API SchematicSystem_Main