Package me.desht.pneumaticcraft.client
Record Class MicromissileClientTooltip
java.lang.Object
java.lang.Record
me.desht.pneumaticcraft.client.MicromissileClientTooltip
- All Implemented Interfaces:
net.minecraft.client.gui.screens.inventory.tooltip.ClientTooltipComponent
public record MicromissileClientTooltip(MicromissilesItem.Tooltip component)
extends Record
implements net.minecraft.client.gui.screens.inventory.tooltip.ClientTooltipComponent
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of aMicromissileClientTooltiprecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecomponentrecord component.final booleanIndicates whether some other object is "equal to" this one.intintgetWidth(net.minecraft.client.gui.Font pFont) final inthashCode()Returns a hash code value for this object.voidrenderImage(net.minecraft.client.gui.Font pFont, int pMouseX, int pMouseY, net.minecraft.client.gui.GuiGraphics graphics) voidrenderText(net.minecraft.client.gui.Font pFont, int pX, int pY, org.joml.Matrix4f pMatrix4f, net.minecraft.client.renderer.MultiBufferSource.BufferSource pBufferSource) final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
MicromissileClientTooltip
Creates an instance of aMicromissileClientTooltiprecord class.- Parameters:
component- the value for thecomponentrecord component
-
-
Method Details
-
renderText
public void renderText(net.minecraft.client.gui.Font pFont, int pX, int pY, org.joml.Matrix4f pMatrix4f, net.minecraft.client.renderer.MultiBufferSource.BufferSource pBufferSource) - Specified by:
renderTextin interfacenet.minecraft.client.gui.screens.inventory.tooltip.ClientTooltipComponent
-
renderImage
public void renderImage(net.minecraft.client.gui.Font pFont, int pMouseX, int pMouseY, net.minecraft.client.gui.GuiGraphics graphics) - Specified by:
renderImagein interfacenet.minecraft.client.gui.screens.inventory.tooltip.ClientTooltipComponent
-
getHeight
public int getHeight()- Specified by:
getHeightin interfacenet.minecraft.client.gui.screens.inventory.tooltip.ClientTooltipComponent
-
getWidth
public int getWidth(net.minecraft.client.gui.Font pFont) - Specified by:
getWidthin interfacenet.minecraft.client.gui.screens.inventory.tooltip.ClientTooltipComponent
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
component
Returns the value of thecomponentrecord component.- Returns:
- the value of the
componentrecord component
-