Record Class SulfurCubeArchetype.ContactDamage
java.lang.Object
java.lang.Record
net.minestom.server.entity.metadata.cube.SulfurCubeArchetype.ContactDamage
- Enclosing interface:
SulfurCubeArchetype
public static record SulfurCubeArchetype.ContactDamage(RegistryKey<DamageType> damageType, Codec.RawValue amount, boolean attributeToSource)
extends Record
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionContactDamage(RegistryKey<DamageType> damageType, Codec.RawValue amount, boolean attributeToSource) Creates an instance of aContactDamagerecord class. -
Method Summary
Modifier and TypeMethodDescriptionamount()Returns the value of theamountrecord component.booleanReturns the value of theattributeToSourcerecord component.Returns the value of thedamageTyperecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
CODEC
-
-
Constructor Details
-
ContactDamage
public ContactDamage(RegistryKey<DamageType> damageType, Codec.RawValue amount, boolean attributeToSource) Creates an instance of aContactDamagerecord class.- Parameters:
damageType- the value for thedamageTyperecord componentamount- the value for theamountrecord componentattributeToSource- the value for theattributeToSourcerecord component
-
-
Method Details
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
damageType
Returns the value of thedamageTyperecord component.- Returns:
- the value of the
damageTyperecord component
-
amount
Returns the value of theamountrecord component.- Returns:
- the value of the
amountrecord component
-
attributeToSource
public boolean attributeToSource()Returns the value of theattributeToSourcerecord component.- Returns:
- the value of the
attributeToSourcerecord component
-