Home Commands Examples Getting Started With Scripts Global Keywords
Generic Recipe Manipulation

BasicSoil

Importing the class

If you need to reference this type directly, like when casting an Array, or as a parameter, you will need to import it. Simply add the import at the top of the file.

script.zs
import mods.botanypotstweaker.soil.BasicSoil;

Extends

BasicSoil extends Soil.

Implements

BasicSoil implements the following interfaces:

Recipe<Container>

Members

Getter
Gets a list of categories that this soil is part of.
script.zs
// BasicSoil.categories as List<string>
myBasicSoil.categories

Return Type: List<string>

Getter
Gets the DisplayState of this soil
script.zs
// BasicSoil.displayState as DisplayState
myBasicSoil.displayState

Return Type: DisplayState

Getter
Gets the growth modifier that this soil applies
script.zs
// BasicSoil.growthModifier as float
myBasicSoil.growthModifier

Return Type: float

Getter
Gets the ingredient of this soil.
script.zs
// BasicSoil.ingredient as IIngredient
myBasicSoil.ingredient

Return Type: IIngredient

Getter
Gets the light level that this soil gives off.
script.zs
// BasicSoil.lightLevel as int
myBasicSoil.lightLevel

Return Type: int

static of(id as ResourceLocation, ingredient as IIngredient, displayState as DisplayState, categories as List<string>, growthModifier as float = 1.0, lightLevel as int = 0) as BasicSoil
Creates a new BasicSoil
script.zs
// BasicSoil.of(id as ResourceLocation, ingredient as IIngredient, displayState as DisplayState, categories as List<string>, growthModifier as float = 1.0, lightLevel as int = 0) as BasicSoil;
BasicSoil.of(<resource:crafttweaker:soil_test>, <item:minecraft:dirt>, SimpleDisplayState.of(<blockstate:minecraft:diamond_block>), ["category1", "category2"], 1.5, 7);

Parameters:

id Type: ResourceLocation - The ID of the soil.
ingredient Type: IIngredient - The ingredient that represents the soil.
displayState Type: DisplayState - The display state of the soil.
categories Type: List<string> - The categories that the soil belongs to.
growthModifier (optional) Type: float - The optional growth modifier of the soil. Defaults to 1.

Default Value: 1.0

lightLevel (optional) Type: int - The optional light level that the soil gives. Defaults to 0.

Default Value: 0

Return Type: BasicSoil