Record Class SectionTextured
java.lang.Object
java.lang.Record
net.mcexpanded.fancytabsections.Section.SectionTextured
- All Implemented Interfaces:
Section
public record SectionTextured(net.minecraft.resources.ResourceLocation id, net.minecraft.network.chat.Component title, net.minecraft.resources.ResourceLocation texture, int textColor, boolean textShadow, boolean collapsible, ConglomerateOfItems items)
extends Record
implements Section
-
Constructor Summary
ConstructorsConstructorDescriptionSectionTextured(net.minecraft.resources.ResourceLocation id, net.minecraft.network.chat.Component title, net.minecraft.resources.ResourceLocation texture, int textColor, boolean textShadow, boolean collapsible, ConglomerateOfItems items) Creates an instance of aSectionTexturedrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the value of thecollapsiblerecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.net.minecraft.resources.ResourceLocationid()Returns the value of theidrecord component.items()Returns the value of theitemsrecord component.static SectionTexturedof(net.minecraft.resources.ResourceLocation id, net.minecraft.network.chat.Component title, int textColor, boolean textShadow, boolean collapsible, ConglomerateOfItems items) The texture must be placed at [namespace]:textures/gui/fancy_tab_section/[path].png when using this buildervoidrender(net.minecraft.client.gui.GuiGraphics guiGraphics, net.minecraft.client.gui.Font font, int topLeftX, int topLeftY) intReturns the value of thetextColorrecord component.booleanReturns the value of thetextShadowrecord component.net.minecraft.resources.ResourceLocationtexture()Returns the value of thetexturerecord component.net.minecraft.network.chat.Componenttitle()Returns the value of thetitlerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SectionTextured
public SectionTextured(net.minecraft.resources.ResourceLocation id, net.minecraft.network.chat.Component title, net.minecraft.resources.ResourceLocation texture, int textColor, boolean textShadow, boolean collapsible, ConglomerateOfItems items) Creates an instance of aSectionTexturedrecord class.- Parameters:
id- the value for theidrecord componenttitle- the value for thetitlerecord componenttexture- the value for thetexturerecord componenttextColor- the value for thetextColorrecord componenttextShadow- the value for thetextShadowrecord componentcollapsible- the value for thecollapsiblerecord componentitems- the value for theitemsrecord component
-
-
Method Details
-
of
public static SectionTextured of(net.minecraft.resources.ResourceLocation id, net.minecraft.network.chat.Component title, int textColor, boolean textShadow, boolean collapsible, ConglomerateOfItems items) The texture must be placed at [namespace]:textures/gui/fancy_tab_section/[path].png when using this builder -
render
public void render(net.minecraft.client.gui.GuiGraphics guiGraphics, net.minecraft.client.gui.Font font, int topLeftX, int topLeftY) -
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. -
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. -
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 '=='. -
id
public net.minecraft.resources.ResourceLocation id()Returns the value of theidrecord component. -
title
public net.minecraft.network.chat.Component title()Returns the value of thetitlerecord component.- Returns:
- the value of the
titlerecord component
-
texture
public net.minecraft.resources.ResourceLocation texture()Returns the value of thetexturerecord component.- Returns:
- the value of the
texturerecord component
-
textColor
public int textColor()Returns the value of thetextColorrecord component.- Returns:
- the value of the
textColorrecord component
-
textShadow
public boolean textShadow()Returns the value of thetextShadowrecord component.- Returns:
- the value of the
textShadowrecord component
-
collapsible
public boolean collapsible()Returns the value of thecollapsiblerecord component.- Specified by:
collapsiblein interfaceSection- Returns:
- the value of the
collapsiblerecord component
-
items
Returns the value of theitemsrecord component.
-