Record Class BedrockActorTint
java.lang.Object
java.lang.Record
com.viaversion.viafabricplus.bedrock.render.BedrockActorTint
- All Implemented Interfaces:
net.minecraft.client.renderer.DynamicGpuDataStorage.DynamicGpuData
public record BedrockActorTint(float red, float green, float blue, float alpha)
extends Record
implements net.minecraft.client.renderer.DynamicGpuDataStorage.DynamicGpuData
Immutable native color-mask input for one prepared actor draw.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionBedrockActorTint(float red, float green, float blue, float alpha) Creates an instance of aBedrockActorTintrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfloatalpha()Returns the value of thealpharecord component.floatblue()Returns the value of thebluerecord component.final booleanIndicates whether some other object is "equal to" this one.floatgreen()Returns the value of thegreenrecord component.final inthashCode()Returns a hash code value for this object.static Optional<BedrockActorTint> palette(net.raphimc.viabedrock.api.model.NativeActorMessage.Colors colors) floatred()Returns the value of theredrecord component.final StringtoString()Returns a string representation of this record class.voidwrite(ByteBuffer buffer)
-
Field Details
-
UNIFORM_SIZE
public static final int UNIFORM_SIZE- See Also:
-
-
Constructor Details
-
BedrockActorTint
public BedrockActorTint(float red, float green, float blue, float alpha) Creates an instance of aBedrockActorTintrecord class.- Parameters:
red- the value for theredrecord componentgreen- the value for thegreenrecord componentblue- the value for thebluerecord componentalpha- the value for thealpharecord component
-
-
Method Details
-
palette
public static Optional<BedrockActorTint> palette(net.raphimc.viabedrock.api.model.NativeActorMessage.Colors colors) -
write
- Specified by:
writein interfacenet.minecraft.client.renderer.DynamicGpuDataStorage.DynamicGpuData
-
toString
-
hashCode
-
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 with thecomparemethod from their corresponding wrapper classes. -
red
public float red()Returns the value of theredrecord component.- Returns:
- the value of the
redrecord component
-
green
public float green()Returns the value of thegreenrecord component.- Returns:
- the value of the
greenrecord component
-
blue
public float blue()Returns the value of thebluerecord component.- Returns:
- the value of the
bluerecord component
-
alpha
public float alpha()Returns the value of thealpharecord component.- Returns:
- the value of the
alpharecord component
-