Skip to content

@minecraft/server


@minecraft/server / BlockStates

Class: BlockStates ​

Defined in: @minecraft/server/index.d.ts:5719

Enumerates all BlockStateTypes.

Methods ​

get() ​

static get(stateName): BlockStateType | undefined

Defined in: @minecraft/server/index.d.ts:5729

Parameters ​

stateName ​

string

Returns ​

BlockStateType | undefined

Returns the Block state instance if it is found. If the block state instance is not found returns undefined.

Remarks ​

Retrieves a specific block state instance.


getAll() ​

static getAll(): BlockStateType[]

Defined in: @minecraft/server/index.d.ts:5735

Returns ​

BlockStateType[]

Remarks ​

Retrieves a set of all available block states.