Record Class BoundingBoxRenderable.RenderableBox
java.lang.Object
java.lang.Record
net.minecraft.world.level.block.entity.BoundingBoxRenderable.RenderableBox
- Enclosing interface:
BoundingBoxRenderable
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionRenderableBox
(BlockPos localPos, Vec3i size) Creates an instance of aRenderableBox
record class. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.fromCorners
(int pX1, int pY1, int pZ1, int pX2, int pY2, int pZ2) final int
hashCode()
Returns a hash code value for this object.localPos()
Returns the value of thelocalPos
record component.size()
Returns the value of thesize
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
localPos
The field for thelocalPos
record component. -
size
The field for thesize
record component.
-
-
Constructor Details
-
RenderableBox
Creates an instance of aRenderableBox
record class.- Parameters:
localPos
- the value for thelocalPos
record componentsize
- the value for thesize
record component
-
-
Method Details
-
fromCorners
public static BoundingBoxRenderable.RenderableBox fromCorners(int pX1, int pY1, int pZ1, int pX2, int pY2, int pZ2) -
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)
. -
localPos
Returns the value of thelocalPos
record component.- Returns:
- the value of the
localPos
record component
-
size
Returns the value of thesize
record component.- Returns:
- the value of the
size
record component
-