PigmentBuilder
This class was added by a mod with mod-id mekanism
. So you need to have this mod installed if you
want to use this feature.
Importing the class
It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.
Extending ChemicalBuilder
PigmentBuilder extends ChemicalBuilder. That means all methods available in ChemicalBuilder are also available in PigmentBuilder
Static Methods
Creates a builder for registering a custom Pigment.
Returns: A builder for creating a custom Pigment.
Return Type: PigmentBuilder
Parameter | Type | Description | Optional | DefaultValue |
---|---|---|---|---|
Parameter textureLocation | Type MCResourceLocation | Description If present the MCResourceLocation representing the texture this Pigment will use, otherwise defaults to our default Pigment texture | Optional true | DefaultValue |
Methods
Create a chemical from this builder with the given name.
Return Type: void
Parameter | Type | Description |
---|---|---|
Parameter name | Type string | Description Registry name for the chemical. |
Sets the tint to apply to this chemical when rendering.
Return Type: CRT_BUILDER
Parameter | Type | Description |
---|---|---|
Parameter color | Type int | Description Color in RRGGBB format |
Sets the color representation to apply to this chemical when used for things like durability bars. Mostly for use in combination with custom textures that are not tinted.
Return Type: CRT_BUILDER
Parameter | Type | Description |
---|---|---|
Parameter color | Type int | Description Color in RRGGBB format |
Adds an attribute to the set of attributes this chemical has.
Return Type: CRT_BUILDER
Parameter | Type | Description |
---|---|---|
Parameter attribute | Type ATTRIBUTE | Description Attribute to add. |