Enum XMaterial

java.lang.Object
java.lang.Enum<XMaterial>
com.cryptomorin.xseries.XMaterial
All Implemented Interfaces:
Serializable, Comparable<XMaterial>, java.lang.constant.Constable

public enum XMaterial
extends Enum<XMaterial>
XMaterial - Data Values/Pre-flattening
1.13 and above as priority.

This class is mainly designed to support ItemStack. If you want to use it on blocks, you'll have to use XBlock

Pre-flattening: https://minecraft.gamepedia.com/Java_Edition_data_values/Pre-flattening Materials: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Material.html Materials (1.12): https://helpch.at/docs/1.12.2/index.html?org/bukkit/Material.html Material IDs: https://minecraft-ids.grahamedgecombe.com/ Material Source Code: https://hub.spigotmc.org/stash/projects/SPIGOT/repos/bukkit/browse/src/main/java/org/bukkit/Material.java XMaterial v1: https://www.spigotmc.org/threads/329630/

This class will throw a "unsupported material" error if someone tries to use an item with an invalid data value which can only happen in 1.12 servers and below or when the utility is missing a new material in that specific version. To get an invalid item, (aka Missing Texture Block) you can use the command /give @p minecraft:dirt 1 10 where 1 is the item amount, and 10 is the data value. The material DIRT with a data value of 10 doesn't exist.

Version:
8.1.1
Author:
Crypto Morin
See Also:
Material, ItemStack