java.lang.Object
java.lang.Record
com.github.minecraftschurlimods.arsmagicalegacy.api.skill.OcculusTab
Record Components:
rendererClass - The path of the renderer class.
background - The location of the background texture for this skill tree.
icon - The location of the icon texture for this skill tree.
width - The width of the background texture.
height - The height of the background texture.
startX - The initial X coordinate of the background texture.
startY - The initial Y coordinate of the background texture.
index - The index this tab should appear at in the occulus.
rendererFactory - The lazy renderer factory. (Only call on the client side)
All Implemented Interfaces:
ITranslatable

public record OcculusTab(String rendererClass, @Nullable net.minecraft.resources.ResourceLocation background, @Nullable net.minecraft.resources.ResourceLocation icon, int width, int height, int startX, int startY, int index, Supplier<OcculusTab.OcculusTabRendererFactory> rendererFactory) extends Record implements ITranslatable
  • Field Details

  • Constructor Details

    • OcculusTab

      public OcculusTab(String rendererClass, @Nullable @Nullable net.minecraft.resources.ResourceLocation background, @Nullable @Nullable net.minecraft.resources.ResourceLocation icon, int width, int height, int startX, int startY, int index, Supplier<OcculusTab.OcculusTabRendererFactory> rendererFactory)
      Creates an instance of a OcculusTab record class.
      Parameters:
      rendererClass - the value for the rendererClass record component
      background - the value for the background record component
      icon - the value for the icon record component
      width - the value for the width record component
      height - the value for the height record component
      startX - the value for the startX record component
      startY - the value for the startY record component
      index - the value for the index record component
      rendererFactory - the value for the rendererFactory record component
  • Method Details

    • background

      public net.minecraft.resources.ResourceLocation background(net.minecraft.core.RegistryAccess access)
      Returns:
      The location of the background texture for this skill tree.
    • icon

      public net.minecraft.resources.ResourceLocation icon(net.minecraft.core.RegistryAccess access)
      Returns:
      The location of the icon texture for this skill tree.
    • getId

      public net.minecraft.resources.ResourceLocation getId(net.minecraft.core.RegistryAccess registryAccess)
      Specified by:
      getId in interface ITranslatable
      Returns:
      The id of this object.
    • getType

      public String getType()
      Specified by:
      getType in interface ITranslatable
      Returns:
      The type of this object, for example "block" or "item".
    • rendererClass

      public String rendererClass()
      Returns the value of the rendererClass record component.
      Returns:
      the value of the rendererClass record component
    • 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.
    • background

      @Nullable public @Nullable net.minecraft.resources.ResourceLocation background()
      Returns the value of the background record component.
      Returns:
      the value of the background record component
    • icon

      @Nullable public @Nullable net.minecraft.resources.ResourceLocation icon()
      Returns the value of the icon record component.
      Returns:
      the value of the icon record component
    • width

      public int width()
      Returns the value of the width record component.
      Returns:
      the value of the width record component
    • height

      public int height()
      Returns the value of the height record component.
      Returns:
      the value of the height record component
    • startX

      public int startX()
      Returns the value of the startX record component.
      Returns:
      the value of the startX record component
    • startY

      public int startY()
      Returns the value of the startY record component.
      Returns:
      the value of the startY record component
    • index

      public int index()
      Returns the value of the index record component.
      Returns:
      the value of the index record component
    • rendererFactory

      Returns the value of the rendererFactory record component.
      Returns:
      the value of the rendererFactory record component