public class BlockPalette extends Object
| Modifier and Type | Field and Description |
|---|---|
static BlockPalette |
INSTANCE |
| Constructor and Description |
|---|
BlockPalette() |
| Modifier and Type | Method and Description |
|---|---|
void |
addBlock(org.cloudburstmc.api.block.BlockType type,
BlockSerializer serializer,
org.cloudburstmc.api.block.trait.BlockTrait<?>[] traits,
org.cloudburstmc.api.block.behavior.BlockBehavior behavior) |
void |
generateRuntimeIds() |
org.cloudburstmc.api.block.BlockState |
getBlockState(int runtimeId) |
org.cloudburstmc.api.block.BlockState |
getBlockState(com.nukkitx.nbt.NbtMap tag) |
org.cloudburstmc.api.block.BlockState |
getDefaultState(org.cloudburstmc.api.block.BlockType blockType) |
int |
getRuntimeId(org.cloudburstmc.api.block.BlockState blockState) |
com.nukkitx.nbt.NbtMap |
getSerialized(org.cloudburstmc.api.block.BlockState state) |
Map<com.nukkitx.nbt.NbtMap,org.cloudburstmc.api.block.BlockState> |
getSerializedPalette() |
org.cloudburstmc.api.block.BlockState |
getState(org.cloudburstmc.api.util.Identifier id) |
org.cloudburstmc.api.block.BlockState |
getState(org.cloudburstmc.api.util.Identifier id,
Map<String,Object> traits) |
Map<org.cloudburstmc.api.block.BlockState,com.nukkitx.nbt.NbtMap> |
getStateMap() |
Set<String> |
getTraits(org.cloudburstmc.api.util.Identifier blockId) |
Map<String,Set<Object>> |
getVanillaTraitMap() |
public static final BlockPalette INSTANCE
public void addBlock(org.cloudburstmc.api.block.BlockType type,
BlockSerializer serializer,
org.cloudburstmc.api.block.trait.BlockTrait<?>[] traits,
org.cloudburstmc.api.block.behavior.BlockBehavior behavior)
public void generateRuntimeIds()
public org.cloudburstmc.api.block.BlockState getState(org.cloudburstmc.api.util.Identifier id)
public org.cloudburstmc.api.block.BlockState getState(org.cloudburstmc.api.util.Identifier id,
Map<String,Object> traits)
public org.cloudburstmc.api.block.BlockState getDefaultState(org.cloudburstmc.api.block.BlockType blockType)
public org.cloudburstmc.api.block.BlockState getBlockState(int runtimeId)
@Nullable public org.cloudburstmc.api.block.BlockState getBlockState(com.nukkitx.nbt.NbtMap tag)
public int getRuntimeId(org.cloudburstmc.api.block.BlockState blockState)
public com.nukkitx.nbt.NbtMap getSerialized(org.cloudburstmc.api.block.BlockState state)
public Map<com.nukkitx.nbt.NbtMap,org.cloudburstmc.api.block.BlockState> getSerializedPalette()
public Map<org.cloudburstmc.api.block.BlockState,com.nukkitx.nbt.NbtMap> getStateMap()
Copyright © 2021. All rights reserved.