Package net.minecraft.gizmos
Record Class CircleGizmo
java.lang.Object
java.lang.Record
net.minecraft.gizmos.CircleGizmo
- All Implemented Interfaces:
Gizmo
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final intprivate final Vec3The field for theposrecord component.private final floatThe field for theradiusrecord component.private static final floatprivate final GizmoStyleThe field for thestylerecord component. -
Constructor Summary
ConstructorsConstructorDescriptionCircleGizmo(Vec3 pos, float radius, GizmoStyle style) Creates an instance of aCircleGizmorecord class. -
Method Summary
Modifier and TypeMethodDescriptionvoidemit(GizmoPrimitives p_455055_, float p_458020_) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.pos()Returns the value of theposrecord component.floatradius()Returns the value of theradiusrecord component.style()Returns the value of thestylerecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
pos
The field for theposrecord component. -
radius
private final float radiusThe field for theradiusrecord component. -
style
The field for thestylerecord component. -
CIRCLE_VERTICES
private static final int CIRCLE_VERTICES- See Also:
-
SEGMENT_SIZE_RADIANS
private static final float SEGMENT_SIZE_RADIANS- See Also:
-
-
Constructor Details
-
CircleGizmo
Creates an instance of aCircleGizmorecord class.- Parameters:
pos- the value for theposrecord componentradius- the value for theradiusrecord componentstyle- the value for thestylerecord component
-
-
Method Details
-
emit
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
pos
Returns the value of theposrecord component.- Returns:
- the value of the
posrecord component
-
radius
public float radius()Returns the value of theradiusrecord component.- Returns:
- the value of the
radiusrecord component
-
style
Returns the value of thestylerecord component.- Returns:
- the value of the
stylerecord component
-