of

fun of(vararg materials: Material): CMatterImpl

Returns CMatterImpl build from specified materials.

// below 2 matters are same
val matter = CMatterImpl.of(Material.STONE, Material.COBBLESTONE)

val matter = CMatterImpl(
name = "STONE-COBBLESTONE",
candidate = setOf(Material.STONE, Material.COBBLESTONE),
amount = 1,
mass = false,
predicates = null
)

Return

CMatterImpl Built matter

Parameters

materials

Candidate materials

Throws

Throws when materials is empty and contains invalid material