Record Class CustomBlockDefinition
java.lang.Object
java.lang.Record
fr.ghostrider584.axiom.block.CustomBlockDefinition
public record CustomBlockDefinition(net.kyori.adventure.key.Key id, String translationKey, List<CustomBlockDefinition.Property> properties, List<Integer> states, net.minestom.server.item.ItemStack pickItem, Set<CustomBlockDefinition.Placement> placement, Map<Integer,Integer> rotateY, Map<Integer,Integer> flipX, Map<Integer,Integer> flipY, Map<Integer,Integer> flipZ)
extends Record
Tool-neutral values, exact 26.2 carriers and explicit transforms for Axiom's v2 block catalogue.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic final recordstatic enumState list uses the Cartesian product in this property/value order (last property varies fastest). -
Constructor Summary
ConstructorsConstructorDescriptionCustomBlockDefinition(net.kyori.adventure.key.Key id, String translationKey, List<CustomBlockDefinition.Property> properties, List<Integer> states, net.minestom.server.item.ItemStack pickItem, Set<CustomBlockDefinition.Placement> placement, Map<Integer, Integer> rotateY, Map<Integer, Integer> flipX, Map<Integer, Integer> flipY, Map<Integer, Integer> flipZ) Creates an instance of aCustomBlockDefinitionrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.flipX()Returns the value of theflipXrecord component.flipY()Returns the value of theflipYrecord component.flipZ()Returns the value of theflipZrecord component.final inthashCode()Returns a hash code value for this object.net.kyori.adventure.key.Keyid()Returns the value of theidrecord component.net.minestom.server.item.ItemStackpickItem()Returns the value of thepickItemrecord component.Returns the value of theplacementrecord component.Returns the value of thepropertiesrecord component.rotateY()Returns the value of therotateYrecord component.states()Returns the value of thestatesrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of thetranslationKeyrecord component.voidwrite(net.minestom.server.network.NetworkBuffer buffer)
-
Constructor Details
-
CustomBlockDefinition
public CustomBlockDefinition(net.kyori.adventure.key.Key id, String translationKey, List<CustomBlockDefinition.Property> properties, List<Integer> states, net.minestom.server.item.ItemStack pickItem, Set<CustomBlockDefinition.Placement> placement, Map<Integer, Integer> rotateY, Map<Integer, Integer> flipX, Map<Integer, Integer> flipY, Map<Integer, Integer> flipZ) Creates an instance of aCustomBlockDefinitionrecord class.- Parameters:
id- the value for theidrecord componenttranslationKey- the value for thetranslationKeyrecord componentproperties- the value for thepropertiesrecord componentstates- the value for thestatesrecord componentpickItem- the value for thepickItemrecord componentplacement- the value for theplacementrecord componentrotateY- the value for therotateYrecord componentflipX- the value for theflipXrecord componentflipY- the value for theflipYrecord componentflipZ- the value for theflipZrecord component
-
-
Method Details
-
write
public void write(net.minestom.server.network.NetworkBuffer buffer) -
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. All components in this record class are compared withObjects::equals(Object,Object). -
id
public net.kyori.adventure.key.Key id()Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
translationKey
Returns the value of thetranslationKeyrecord component.- Returns:
- the value of the
translationKeyrecord component
-
properties
Returns the value of thepropertiesrecord component.- Returns:
- the value of the
propertiesrecord component
-
states
-
pickItem
public net.minestom.server.item.ItemStack pickItem()Returns the value of thepickItemrecord component.- Returns:
- the value of the
pickItemrecord component
-
placement
Returns the value of theplacementrecord component.- Returns:
- the value of the
placementrecord component
-
rotateY
-
flipX
-
flipY
-
flipZ
-