Package foundry.veil.api.quasar.data
Record Class EmitterShapeSettings
java.lang.Object
java.lang.Record
foundry.veil.api.quasar.data.EmitterShapeSettings
public record EmitterShapeSettings(EmitterShape shape, org.joml.Vector3fc dimensions, org.joml.Vector3fc rotation, boolean fromSurface)
extends Record
-
Field Summary
Modifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec
<net.minecraft.core.Holder<EmitterShapeSettings>> static final com.mojang.serialization.Codec
<EmitterShapeSettings> -
Constructor Summary
ConstructorDescriptionEmitterShapeSettings
(EmitterShape shape, org.joml.Vector3fc dimensions, org.joml.Vector3fc rotation, boolean fromSurface) Creates an instance of aEmitterShapeSettings
record class. -
Method Summary
Modifier and TypeMethodDescriptionorg.joml.Vector3fc
Returns the value of thedimensions
record component.final boolean
Indicates whether some other object is "equal to" this one.boolean
Returns the value of thefromSurface
record component.org.joml.Vector3d
getPos
(net.minecraft.util.RandomSource randomSource, org.joml.Vector3dc pos) @Nullable net.minecraft.resources.ResourceLocation
final int
hashCode()
Returns a hash code value for this object.org.joml.Vector3fc
rotation()
Returns the value of therotation
record component.shape()
Returns the value of theshape
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
DIRECT_CODEC
-
CODEC
public static final com.mojang.serialization.Codec<net.minecraft.core.Holder<EmitterShapeSettings>> CODEC
-
-
Constructor Details
-
EmitterShapeSettings
public EmitterShapeSettings(EmitterShape shape, org.joml.Vector3fc dimensions, org.joml.Vector3fc rotation, boolean fromSurface) Creates an instance of aEmitterShapeSettings
record class.- Parameters:
shape
- the value for theshape
record componentdimensions
- the value for thedimensions
record componentrotation
- the value for therotation
record componentfromSurface
- the value for thefromSurface
record component
-
-
Method Details
-
getPos
public org.joml.Vector3d getPos(net.minecraft.util.RandomSource randomSource, org.joml.Vector3dc pos) -
getRegistryId
@Nullable public @Nullable net.minecraft.resources.ResourceLocation getRegistryId() -
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 '=='. -
shape
Returns the value of theshape
record component.- Returns:
- the value of the
shape
record component
-
dimensions
public org.joml.Vector3fc dimensions()Returns the value of thedimensions
record component.- Returns:
- the value of the
dimensions
record component
-
rotation
public org.joml.Vector3fc rotation()Returns the value of therotation
record component.- Returns:
- the value of the
rotation
record component
-
fromSurface
public boolean fromSurface()Returns the value of thefromSurface
record component.- Returns:
- the value of the
fromSurface
record component
-