Record Class ConditionalBlockModel.Unbaked
java.lang.Object
java.lang.Record
net.minecraft.client.renderer.block.model.ConditionalBlockModel.Unbaked
- All Implemented Interfaces:
BlockModel.Unbaked
- Enclosing class:
ConditionalBlockModel
public static record ConditionalBlockModel.Unbaked(Optional<Transformation> transformation, ConditionalBlockModelProperty property, BlockModel.Unbaked onTrue, BlockModel.Unbaked onFalse)
extends Record
implements BlockModel.Unbaked
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final BlockModel.UnbakedThe field for theonFalserecord component.private final BlockModel.UnbakedThe field for theonTruerecord component.private final ConditionalBlockModelPropertyThe field for thepropertyrecord component.private final Optional<Transformation> The field for thetransformationrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionUnbaked(Optional<Transformation> transformation, ConditionalBlockModelProperty property, BlockModel.Unbaked onTrue, BlockModel.Unbaked onFalse) Creates an instance of aUnbakedrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbake(BlockModel.BakingContext context, org.joml.Matrix4fc transformation) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.onFalse()Returns the value of theonFalserecord component.onTrue()Returns the value of theonTruerecord component.property()Returns the value of thepropertyrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of thetransformationrecord component.
-
Field Details
-
transformation
The field for thetransformationrecord component. -
property
The field for thepropertyrecord component. -
onTrue
The field for theonTruerecord component. -
onFalse
The field for theonFalserecord component.
-
-
Constructor Details
-
Unbaked
public Unbaked(Optional<Transformation> transformation, ConditionalBlockModelProperty property, BlockModel.Unbaked onTrue, BlockModel.Unbaked onFalse) Creates an instance of aUnbakedrecord class.- Parameters:
transformation- the value for thetransformationrecord componentproperty- the value for thepropertyrecord componentonTrue- the value for theonTruerecord componentonFalse- the value for theonFalserecord component
-
-
Method Details
-
bake
- Specified by:
bakein interfaceBlockModel.Unbaked
-
toString
-
hashCode
-
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). -
transformation
Returns the value of thetransformationrecord component.- Returns:
- the value of the
transformationrecord component
-
property
Returns the value of thepropertyrecord component.- Returns:
- the value of the
propertyrecord component
-
onTrue
Returns the value of theonTruerecord component.- Returns:
- the value of the
onTruerecord component
-
onFalse
Returns the value of theonFalserecord component.- Returns:
- the value of the
onFalserecord component
-