Package de.rasmusantons.cubiomes
Record Class Range
java.lang.Object
java.lang.Record
de.rasmusantons.cubiomes.Range
- Record Components:
scale- Horizontal scale factor, should be one of 1, 4, 16, 64, or 256 additionally a value of zero bypasses scaling and expects a manual generation entry layer.x- Lower end of the x-range (west face of the cube)z- Lower end of the z-range (north face of the cube)sx- Size along the x-axissz- Size along the z-axisy- Lower and of the y-range (bottom face of the cube)sy- Vertical size
Defines an area or volume for the biome generation. It is given by a
position, size and scaling in the horizontal axes, and an optional
vertical range. The vertical scaling is equal to 1:1 iff scale == 1,
and 1:4 (default biome scale) in all other cases!
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intscale()Returns the value of thescalerecord component.intsx()Returns the value of thesxrecord component.intsy()Returns the value of thesyrecord component.intsz()Returns the value of theszrecord component.final StringtoString()Returns a string representation of this record class.intx()Returns the value of thexrecord component.inty()Returns the value of theyrecord component.intz()Returns the value of thezrecord component.
-
Constructor Details
-
Range
public Range(int scale, int x, int z, int sx, int sz, int y) -
Range
public Range(int scale, int x, int z, int sx, int sz, int y, int sy) Creates an instance of aRangerecord class.- Parameters:
scale- the value for thescalerecord componentx- the value for thexrecord componentz- the value for thezrecord componentsx- the value for thesxrecord componentsz- the value for theszrecord componenty- the value for theyrecord componentsy- the value for thesyrecord 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. All components in this record class are compared with '=='. -
scale
public int scale()Returns the value of thescalerecord component.- Returns:
- the value of the
scalerecord component
-
x
public int x()Returns the value of thexrecord component.- Returns:
- the value of the
xrecord component
-
z
public int z()Returns the value of thezrecord component.- Returns:
- the value of the
zrecord component
-
sx
public int sx()Returns the value of thesxrecord component.- Returns:
- the value of the
sxrecord component
-
sz
public int sz()Returns the value of theszrecord component.- Returns:
- the value of the
szrecord component
-
y
public int y()Returns the value of theyrecord component.- Returns:
- the value of the
yrecord component
-
sy
public int sy()Returns the value of thesyrecord component.- Returns:
- the value of the
syrecord component
-