Record Class AltarMaterial
java.lang.Object
java.lang.Record
at.minecraftschurli.mods.arsmagicalegacy.api.magic.AltarMaterial
- Record Components:
block- TheBlockof the material.stair- TheStairBlockof the material.power- The power of the material.
public record AltarMaterial(net.minecraft.world.level.block.Block block, net.minecraft.world.level.block.StairBlock stair, int power)
extends Record
Represents an altar's material.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<net.minecraft.core.Holder<AltarMaterial>> static final com.mojang.serialization.Codec<AltarMaterial> -
Constructor Summary
ConstructorsConstructorDescriptionAltarMaterial(net.minecraft.world.level.block.Block block, net.minecraft.world.level.block.StairBlock stair, int power) Creates an instance of aAltarMaterialrecord class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.world.level.block.Blockblock()Returns the value of theblockrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intpower()Returns the value of thepowerrecord component.net.minecraft.world.level.block.StairBlockstair()Returns the value of thestairrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
DIRECT_CODEC
-
CODEC
-
-
Constructor Details
-
AltarMaterial
public AltarMaterial(net.minecraft.world.level.block.Block block, net.minecraft.world.level.block.StairBlock stair, int power) Creates an instance of aAltarMaterialrecord class.
-
-
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. -
block
-
stair
-
power
-