Record Class CarryOnScript.ScriptRender

java.lang.Object
java.lang.Record
tschipp.carryon.common.scripting.CarryOnScript.ScriptRender
Enclosing class:
CarryOnScript

public static record CarryOnScript.ScriptRender(Optional<net.minecraft.resources.ResourceKey<net.minecraft.world.level.block.Block>> renderNameBlock, Optional<net.minecraft.resources.ResourceKey<net.minecraft.world.entity.EntityType<?>>> renderNameEntity, Optional<net.minecraft.nbt.CompoundTag> renderNBT, Matchables.OptionalVec3 renderTranslation, Matchables.OptionalVec3 renderRotation, Matchables.OptionalVec3 renderscale, Matchables.OptionalVec3 renderRotationLeftArm, Matchables.OptionalVec3 renderRotationRightArm, boolean renderLeftArm, boolean renderRightArm) extends Record
  • Field Details

  • Constructor Details

    • ScriptRender

      public ScriptRender(Optional<net.minecraft.resources.ResourceKey<net.minecraft.world.level.block.Block>> renderNameBlock, Optional<net.minecraft.resources.ResourceKey<net.minecraft.world.entity.EntityType<?>>> renderNameEntity, Optional<net.minecraft.nbt.CompoundTag> renderNBT, Matchables.OptionalVec3 renderTranslation, Matchables.OptionalVec3 renderRotation, Matchables.OptionalVec3 renderscale, Matchables.OptionalVec3 renderRotationLeftArm, Matchables.OptionalVec3 renderRotationRightArm, boolean renderLeftArm, boolean renderRightArm)
      Creates an instance of a ScriptRender record class.
      Parameters:
      renderNameBlock - the value for the renderNameBlock record component
      renderNameEntity - the value for the renderNameEntity record component
      renderNBT - the value for the renderNBT record component
      renderTranslation - the value for the renderTranslation record component
      renderRotation - the value for the renderRotation record component
      renderscale - the value for the renderscale record component
      renderRotationLeftArm - the value for the renderRotationLeftArm record component
      renderRotationRightArm - the value for the renderRotationRightArm record component
      renderLeftArm - the value for the renderLeftArm record component
      renderRightArm - the value for the renderRightArm record component
  • Method Details

    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • 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.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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 with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • renderNameBlock

      public Optional<net.minecraft.resources.ResourceKey<net.minecraft.world.level.block.Block>> renderNameBlock()
      Returns the value of the renderNameBlock record component.
      Returns:
      the value of the renderNameBlock record component
    • renderNameEntity

      public Optional<net.minecraft.resources.ResourceKey<net.minecraft.world.entity.EntityType<?>>> renderNameEntity()
      Returns the value of the renderNameEntity record component.
      Returns:
      the value of the renderNameEntity record component
    • renderNBT

      public Optional<net.minecraft.nbt.CompoundTag> renderNBT()
      Returns the value of the renderNBT record component.
      Returns:
      the value of the renderNBT record component
    • renderTranslation

      public Matchables.OptionalVec3 renderTranslation()
      Returns the value of the renderTranslation record component.
      Returns:
      the value of the renderTranslation record component
    • renderRotation

      public Matchables.OptionalVec3 renderRotation()
      Returns the value of the renderRotation record component.
      Returns:
      the value of the renderRotation record component
    • renderscale

      public Matchables.OptionalVec3 renderscale()
      Returns the value of the renderscale record component.
      Returns:
      the value of the renderscale record component
    • renderRotationLeftArm

      public Matchables.OptionalVec3 renderRotationLeftArm()
      Returns the value of the renderRotationLeftArm record component.
      Returns:
      the value of the renderRotationLeftArm record component
    • renderRotationRightArm

      public Matchables.OptionalVec3 renderRotationRightArm()
      Returns the value of the renderRotationRightArm record component.
      Returns:
      the value of the renderRotationRightArm record component
    • renderLeftArm

      public boolean renderLeftArm()
      Returns the value of the renderLeftArm record component.
      Returns:
      the value of the renderLeftArm record component
    • renderRightArm

      public boolean renderRightArm()
      Returns the value of the renderRightArm record component.
      Returns:
      the value of the renderRightArm record component