Class MaterialCompat
java.lang.Object
io.github.addoncommunity.galactifun.util.MaterialCompat
Resolves
XMaterial constants to a Material that exists on the
running server. Keeps Galactifun loadable on legacy versions where modern
constants (e.g. NETHERITE_INGOT, *_CONCRETE_POWDER) are absent.-
Method Summary
Modifier and TypeMethodDescriptionstatic org.bukkit.Materialsafe(io.github.thebusybiscuit.slimefun5.libraries.xseries.XMaterial material) static org.bukkit.inventory.ItemStackstack(io.github.thebusybiscuit.slimefun5.libraries.xseries.XMaterial material) Resolves an XMaterial to an ItemStack, preserving the legacy data value safe(XMaterial) drops on 1.8-1.12.
-
Method Details
-
safe
@Nonnull public static org.bukkit.Material safe(@Nonnull io.github.thebusybiscuit.slimefun5.libraries.xseries.XMaterial material) -
stack
@Nonnull public static org.bukkit.inventory.ItemStack stack(@Nonnull io.github.thebusybiscuit.slimefun5.libraries.xseries.XMaterial material) Resolves an XMaterial to an ItemStack, preserving the legacy data value safe(XMaterial) drops on 1.8-1.12.
-