Archiviert
13
0

Expand MaterialTags (#3964)

Dieser Commit ist enthalten in:
Ineusia 2020-07-22 01:20:57 -05:00 committet von GitHub
Ursprung cc25ae47c0
Commit 2e11235d1d
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 4AEE18F83AFDEB23

Datei anzeigen

@ -204,10 +204,10 @@ index 0000000000000000000000000000000000000000..c91ea2a0679a7f3a5627b5a008e0b39d
+}
diff --git a/src/main/java/com/destroystokyo/paper/MaterialTags.java b/src/main/java/com/destroystokyo/paper/MaterialTags.java
new file mode 100644
index 0000000000000000000000000000000000000000..e72fc52240015051fe58b246fcf5c014f3330f0a
index 0000000000000000000000000000000000000000..4932bd60d30b73e03fecc75f57212f46881d2843
--- /dev/null
+++ b/src/main/java/com/destroystokyo/paper/MaterialTags.java
@@ -0,0 +1,410 @@
@@ -0,0 +1,497 @@
+/*
+ * Copyright (c) 2018 Daniel Ennis (Aikar) MIT License
+ *
@ -613,6 +613,93 @@ index 0000000000000000000000000000000000000000..e72fc52240015051fe58b246fcf5c014
+ .add(Material.LANTERN, Material.SOUL_LANTERN)
+ .ensureSize("LANTERNS", 2);
+
+ /**
+ * Covers the variants of rails.
+ */
+ public static final MaterialSetTag RAILS = new MaterialSetTag(keyFor("rails"))
+ .endsWith("RAIL")
+ .ensureSize("RAILS", 4);
+
+ /**
+ * Covers the variants of swords.
+ */
+ public static final MaterialSetTag SWORDS = new MaterialSetTag(keyFor("swords"))
+ .endsWith("_SWORD")
+ .ensureSize("SWORDS", 6);
+
+ /**
+ * Covers the variants of shovels.
+ */
+ public static final MaterialSetTag SHOVELS = new MaterialSetTag(keyFor("shovels"))
+ .endsWith("_SHOVEL")
+ .ensureSize("SHOVELS", 6);
+
+ /**
+ * Covers the variants of pickaxes.
+ */
+ public static final MaterialSetTag PICKAXES = new MaterialSetTag(keyFor("pickaxes"))
+ .endsWith("_PICKAXE")
+ .ensureSize("PICKAXES", 6);
+
+ /**
+ * Covers the variants of axes.
+ */
+ public static final MaterialSetTag AXES = new MaterialSetTag(keyFor("axes"))
+ .endsWith("_AXE")
+ .ensureSize("AXES", 6);
+
+ /**
+ * Covers the variants of hoes.
+ */
+ public static final MaterialSetTag HOES = new MaterialSetTag(keyFor("hoes"))
+ .endsWith("_HOE")
+ .ensureSize("HOES", 6);
+
+ /**
+ * Covers the variants of helmets.
+ */
+ public static final MaterialSetTag HELMETS = new MaterialSetTag(keyFor("helmets"))
+ .endsWith("_HELMET")
+ .ensureSize("HELMETS", 7);
+
+ /**
+ * Covers the variants of items that can be equipped in the helmet slot.
+ */
+ public static final MaterialSetTag HEAD_EQUIPPABLE = new MaterialSetTag(keyFor("head_equippable"))
+ .endsWith("_HELMET")
+ .add(SKULLS)
+ .add(Material.CARVED_PUMPKIN)
+ .ensureSize("HEAD_EQUIPPABLE", 20);
+
+ /**
+ * Covers the variants of chestplate.
+ */
+ public static final MaterialSetTag CHESTPLATES = new MaterialSetTag(keyFor("chestplates"))
+ .endsWith("_CHESTPLATE")
+ .ensureSize("CHESTPLATES", 6);
+
+ /**
+ * Covers the variants of items that can be equipped in the chest slot.
+ */
+ public static final MaterialSetTag CHEST_EQUIPPABLE = new MaterialSetTag(keyFor("chest_equippable"))
+ .endsWith("_CHESTPLATE")
+ .add(Material.ELYTRA)
+ .ensureSize("CHEST_EQUIPPABLE", 7);
+
+ /**
+ * Covers the variants of leggings.
+ */
+ public static final MaterialSetTag LEGGINGS = new MaterialSetTag(keyFor("leggings"))
+ .endsWith("_LEGGINGS")
+ .ensureSize("LEGGINGS", 6);
+
+ /**
+ * Covers the variants of boots.
+ */
+ public static final MaterialSetTag BOOTS = new MaterialSetTag(keyFor("boots"))
+ .endsWith("_BOOTS")
+ .ensureSize("BOOTS", 6);
+
+ @SuppressWarnings("unchecked")
+ public static final MaterialSetTag COLORABLE = new MaterialSetTag(keyFor("colorable"))
+ .add(Tag.WOOL, Tag.CARPETS).add(SHULKER_BOXES, STAINED_GLASS, STAINED_GLASS_PANES, CONCRETES, BEDS);