Package net.minecraft.world.level.biome
Record Class Biome.ClimateSettings
java.lang.Object
java.lang.Record
net.minecraft.world.level.biome.Biome.ClimateSettings
- Enclosing class:
- Biome
public static record Biome.ClimateSettings(Biome.Precipitation precipitation, float temperature, Biome.TemperatureModifier temperatureModifier, float downfall)
extends Record
-
Field Summary
Modifier and TypeFieldDescriptionstatic final com.mojang.serialization.MapCodec<Biome.ClimateSettings>
private final float
The field for thedownfall
record component.private final Biome.Precipitation
The field for theprecipitation
record component.private final float
The field for thetemperature
record component.private final Biome.TemperatureModifier
The field for thetemperatureModifier
record component. -
Constructor Summary
ConstructorDescriptionClimateSettings
(Biome.Precipitation precipitation, float temperature, Biome.TemperatureModifier temperatureModifier, float downfall) Creates an instance of aClimateSettings
record class. -
Method Summary
Modifier and TypeMethodDescriptionfloat
downfall()
Returns the value of thedownfall
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.Returns the value of theprecipitation
record component.float
Returns the value of thetemperature
record component.Returns the value of thetemperatureModifier
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
precipitation
The field for theprecipitation
record component. -
temperature
private final float temperatureThe field for thetemperature
record component. -
temperatureModifier
The field for thetemperatureModifier
record component. -
downfall
private final float downfallThe field for thedownfall
record component. -
CODEC
-
-
Constructor Details
-
ClimateSettings
public ClimateSettings(Biome.Precipitation precipitation, float temperature, Biome.TemperatureModifier temperatureModifier, float downfall) Creates an instance of aClimateSettings
record class.- Parameters:
precipitation
- the value for theprecipitation
record componenttemperature
- the value for thetemperature
record componenttemperatureModifier
- the value for thetemperatureModifier
record componentdownfall
- the value for thedownfall
record component
-
-
Method Details
-
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 '=='. -
precipitation
Returns the value of theprecipitation
record component.- Returns:
- the value of the
precipitation
record component
-
temperature
public float temperature()Returns the value of thetemperature
record component.- Returns:
- the value of the
temperature
record component
-
temperatureModifier
Returns the value of thetemperatureModifier
record component.- Returns:
- the value of the
temperatureModifier
record component
-
downfall
public float downfall()Returns the value of thedownfall
record component.- Returns:
- the value of the
downfall
record component
-