Record Class CardinalLighting
java.lang.Object
java.lang.Record
net.minecraft.world.level.CardinalLighting
public record CardinalLighting(float down, float up, float north, float south, float west, float east)
extends Record
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final CardinalLightingprivate final floatThe field for thedownrecord component.private final floatThe field for theeastrecord component.static final CardinalLightingprivate final floatThe field for thenorthrecord component.private final floatThe field for thesouthrecord component.private final floatThe field for theuprecord component.private final floatThe field for thewestrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionCardinalLighting(float down, float up, float north, float south, float west, float east) Creates an instance of aCardinalLightingrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfloatfloatdown()Returns the value of thedownrecord component.floateast()Returns the value of theeastrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.floatnorth()Returns the value of thenorthrecord component.floatsouth()Returns the value of thesouthrecord component.final StringtoString()Returns a string representation of this record class.floatup()Returns the value of theuprecord component.floatwest()Returns the value of thewestrecord component.
-
Field Details
-
down
private final float downThe field for thedownrecord component. -
up
private final float upThe field for theuprecord component. -
north
private final float northThe field for thenorthrecord component. -
south
private final float southThe field for thesouthrecord component. -
west
private final float westThe field for thewestrecord component. -
east
private final float eastThe field for theeastrecord component. -
DEFAULT
-
NETHER
-
-
Constructor Details
-
CardinalLighting
public CardinalLighting(float down, float up, float north, float south, float west, float east) Creates an instance of aCardinalLightingrecord class.- Parameters:
down- the value for thedownrecord componentup- the value for theuprecord componentnorth- the value for thenorthrecord componentsouth- the value for thesouthrecord componentwest- the value for thewestrecord componenteast- the value for theeastrecord component
-
-
Method Details
-
byFace
-
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 with thecomparemethod from their corresponding wrapper classes. -
down
public float down()Returns the value of thedownrecord component.- Returns:
- the value of the
downrecord component
-
up
public float up()Returns the value of theuprecord component.- Returns:
- the value of the
uprecord component
-
north
public float north()Returns the value of thenorthrecord component.- Returns:
- the value of the
northrecord component
-
south
public float south()Returns the value of thesouthrecord component.- Returns:
- the value of the
southrecord component
-
west
public float west()Returns the value of thewestrecord component.- Returns:
- the value of the
westrecord component
-
east
public float east()Returns the value of theeastrecord component.- Returns:
- the value of the
eastrecord component
-