Record Class DenRenderContext
java.lang.Object
java.lang.Record
com.pixelmonmod.pixelmon.battles.raids.render.DenRenderContext
- Record Components:
entity- The den entity being rendered.entityYaw- The yaw supplied by the entity renderer.partialTicks- The current frame partial tick.poseStack- The active pose stack for the den render.bufferSource- The buffer source for this render call.packedLight- The world light packed value supplied by Minecraft.packedOverlay- The packed overlay value for the den entity.
public record DenRenderContext(DenEntity entity, float entityYaw, float partialTicks, com.mojang.blaze3d.vertex.PoseStack poseStack, net.minecraft.client.renderer.MultiBufferSource bufferSource, int packedLight, int packedOverlay)
extends Record
Client-side render state available to data-driven den render effects.
-
Constructor Summary
ConstructorsConstructorDescriptionDenRenderContext(DenEntity entity, float entityYaw, float partialTicks, com.mojang.blaze3d.vertex.PoseStack poseStack, net.minecraft.client.renderer.MultiBufferSource bufferSource, int packedLight, int packedOverlay) Creates an instance of aDenRenderContextrecord class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.client.renderer.MultiBufferSourceReturns the value of thebufferSourcerecord component.color()Gets the resolved den tint color for this frame.entity()Returns the value of theentityrecord component.floatReturns the value of theentityYawrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.models()Gets the model data used by the den base.intReturns the value of thepackedLightrecord component.intReturns the value of thepackedOverlayrecord component.floatReturns the value of thepartialTicksrecord component.com.mojang.blaze3d.vertex.PoseStackReturns the value of theposeStackrecord component.Gets the raid type render options for the den being rendered.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
DenRenderContext
public DenRenderContext(DenEntity entity, float entityYaw, float partialTicks, com.mojang.blaze3d.vertex.PoseStack poseStack, net.minecraft.client.renderer.MultiBufferSource bufferSource, int packedLight, int packedOverlay) Creates an instance of aDenRenderContextrecord class.- Parameters:
entity- the value for theentityrecord componententityYaw- the value for theentityYawrecord componentpartialTicks- the value for thepartialTicksrecord componentposeStack- the value for theposeStackrecord componentbufferSource- the value for thebufferSourcerecord componentpackedLight- the value for thepackedLightrecord componentpackedOverlay- the value for thepackedOverlayrecord component
-
-
Method Details
-
renderOptions
Gets the raid type render options for the den being rendered.- Returns:
- The active raid type render options.
-
color
Gets the resolved den tint color for this frame.- Returns:
- The active raid tint color, or white when tinting is disabled or the den is inactive.
-
models
Gets the model data used by the den base.- Returns:
- The active den model data.
-
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 '=='. -
entity
Returns the value of theentityrecord component.- Returns:
- the value of the
entityrecord component
-
entityYaw
public float entityYaw()Returns the value of theentityYawrecord component.- Returns:
- the value of the
entityYawrecord component
-
partialTicks
public float partialTicks()Returns the value of thepartialTicksrecord component.- Returns:
- the value of the
partialTicksrecord component
-
poseStack
public com.mojang.blaze3d.vertex.PoseStack poseStack()Returns the value of theposeStackrecord component.- Returns:
- the value of the
poseStackrecord component
-
bufferSource
public net.minecraft.client.renderer.MultiBufferSource bufferSource()Returns the value of thebufferSourcerecord component.- Returns:
- the value of the
bufferSourcerecord component
-
packedLight
public int packedLight()Returns the value of thepackedLightrecord component.- Returns:
- the value of the
packedLightrecord component
-
packedOverlay
public int packedOverlay()Returns the value of thepackedOverlayrecord component.- Returns:
- the value of the
packedOverlayrecord component
-