typeIf

fun typeIf(material: Material, condition: Boolean = false): ItemBuilder(source)

Sets the type of the material in the ItemBuilder, if the given condition is true.

Return

The ItemBuilder instance.

Parameters

material

The material to set.

condition

The condition that determines whether the type should be set.