Record Class MultiVariant
java.lang.Object
java.lang.Record
net.minecraft.client.renderer.block.model.MultiVariant
- All Implemented Interfaces:
UnbakedBlockStateModel,ResolvableModel
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface net.minecraft.client.resources.model.ResolvableModel
ResolvableModel.Resolver -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionMultiVariant(List<Variant> variants) Creates an instance of aMultiVariantrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbake(ModelBaker p_249016_) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.voidresolveDependencies(ResolvableModel.Resolver p_387350_) final StringtoString()Returns a string representation of this record class.variants()Returns the value of thevariantsrecord component.visualEqualityGroup(BlockState p_360999_)
-
Field Details
-
variants
The field for thevariantsrecord component.
-
-
Constructor Details
-
MultiVariant
Creates an instance of aMultiVariantrecord class.- Parameters:
variants- the value for thevariantsrecord component
-
-
Method Details
-
visualEqualityGroup
- Specified by:
visualEqualityGroupin interfaceUnbakedBlockStateModel
-
resolveDependencies
- Specified by:
resolveDependenciesin interfaceResolvableModel
-
bake
- Specified by:
bakein interfaceUnbakedBlockStateModel
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
variants
Returns the value of thevariantsrecord component.- Returns:
- the value of the
variantsrecord component
-