Home Migration Guide Getting Started With Scripts Commands Examples
Generic JSON Recipes

WorldTransmutation

This class was added by a mod with mod-id projecte. 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.

script.zs
import mods.projecte.WorldTransmutation;

Static Methods

Adds an in world transmutation “recipe”.

Return Type: void

script.zs
WorldTransmutation.add(input as MCBlockState, output as MCBlockState, sneakOutput as MCBlockState) as void
ParameterTypeDescriptionOptionalDefaultValue
Parameter
input
Type
MCBlockState
Description
MCBlockState representing the input or target state.
Optional
false
DefaultValue
Parameter
output
Type
MCBlockState
Description
MCBlockState representing the output state.
Optional
false
DefaultValue
Parameter
sneakOutput
Type
MCBlockState
Description
Optional MCBlockState representing the output state when sneaking.
Optional
true
DefaultValue

Removes an existing in world transmutation “recipe”.

Return Type: void

script.zs
WorldTransmutation.remove(input as MCBlockState, output as MCBlockState, sneakOutput as MCBlockState) as void
ParameterTypeDescriptionOptionalDefaultValue
Parameter
input
Type
MCBlockState
Description
MCBlockState representing the input or target state.
Optional
false
DefaultValue
Parameter
output
Type
MCBlockState
Description
MCBlockState representing the output state.
Optional
false
DefaultValue
Parameter
sneakOutput
Type
MCBlockState
Description
Optional MCBlockState representing the output state when sneaking.
Optional
true
DefaultValue

Removes all existing in world transmutation “recipes”.

Return Type: void

script.zs
// WorldTransmutation.removeAll() as void
WorldTransmutation.removeAll();