MCBlockState

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.

ZenScript
Copy
import crafttweaker.api.blocks.MCBlockState;

Casters

Result typeIs Implicit
MCBlocktrue
stringfalse

Methods

getAllowedValuesForProperty

Return Type: stdlib.List<string>

ZenScript
Copy
MCBlockState.getAllowedValuesForProperty(name as string) as stdlib.List<string>
ParameterTypeDescription
namestringNo Description Provided

getProperties

Return Type: string[string]

ZenScript
Copy
MCBlockState.getProperties() as string[string]
myMCBlockState.getProperties();

getPropertyNames

Return Type: stdlib.List<string>

ZenScript
Copy
MCBlockState.getPropertyNames() as stdlib.List<string>
myMCBlockState.getPropertyNames();

getPropertyValue

Return Type: string

ZenScript
Copy
MCBlockState.getPropertyValue(name as string) as string
ParameterTypeDescription
namestringNo Description Provided

hasProperty

Return Type: boolean

ZenScript
Copy
MCBlockState.hasProperty(name as string) as boolean
ParameterTypeDescription
namestringNo Description Provided

withProperty

Return Type: MCBlockState

ZenScript
Copy
MCBlockState.withProperty(name as string, value as string) as MCBlockState
ParameterTypeDescription
namestringNo Description Provided
valuestringNo Description Provided

Properties

NameTypeHas GetterHas Setter
blockMCBlocktruefalse
canProvidePowerbooleantruefalse
commandStringstringtruefalse
hasTileEntitybooleantruefalse
isSolidbooleantruefalse
isStickybooleantruefalse
lightLevelinttruefalse
ticksRandomlybooleantruefalse